• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Tomcat does not load applet

 
fedai gandjaliyev
Ranch Hand
Posts: 99
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello!
I'm facing a problem here that I havent been able to solve for six days.
A month ago I had Windows 2000 running on my machine.
I installed and configured (context.xml, server.xml, web.xml) Tomcat 5.5.9, inserted an applet into a page that I put into the ROOT directory of
the Tomcat installation.
When I typed http://localhost in my browser the page loaded and so did the
the applet. And so it worked when I typed http://my_host_name from a remote
machine.
Then I installed XP Pro.
Did just the same. Everything worked locally.
But when I wanted to load the page from a remote machine the page loaded
but the applet didnt with the commonly known message "class not found".
I'm aware that there is a service running on XP that might conflict with
Tomcat. I stopped it but it didnt help.
I even tried codebase = "http://my_host_name" code = "myapplet.class".

What do you think it might be? I need a solution badly.


[fixed header]
[ January 24, 2006: Message edited by: Ben Souther ]
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
fedai,

Typing in all caps is the equivalent to shouting in a web forum and is considered rude.


- The Bartender.
[ January 24, 2006: Message edited by: Ben Souther ]
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13077
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I even tried codebase = "http://my_host_name" code = "myapplet.class".

I would first try
codebase = "http://my_host_name/"
If that didn't work I would try using the <BASE HTML tag.
How is the page that contains the applet tag being generated? Is it a static page?
Bill
 
fedai gandjaliyev
Ranch Hand
Posts: 99
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What you offered didnt help.
What concerns the page it is a static.
I'm not administrator of our intranet so I cant delete or install
programs whenever I want.
On the applet's machine the JRE1.5 is running but on others is JRE1.4.2
Can the reason be this difference?
 
fedai gandjaliyev
Ranch Hand
Posts: 99
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I havent ever used the "base" html tag.
Could you show me the usage?
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65335
97
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by fedai gandjaliyev:
I havent ever used the "base" html tag.
Could you show me the usage?


The HTML 4 Specification can be found here.
 
fedai gandjaliyev
Ranch Hand
Posts: 99
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What about the JRE versions?
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by fedai gandjaliyev:
What about the JRE versions?


Applets are a client side technology.
The JRE version on the server has nothing to do with whether they work or not.
As far as Tomcat is concerned, your applet files are just static files to be served to the browser; no different than zip files or images.

I'm going to move this thread to the Applets forum for you.
 
fedai gandjaliyev
Ranch Hand
Posts: 99
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is there smth to be configured in the jre5th plug-in to properly load
applets?
 
fedai gandjaliyev
Ranch Hand
Posts: 99
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The problem isnt an ordinary one.
The fact is with 2000 I used just this code = "smpApp.class"
and everything was fine. I browsed the applet's page from
a remote host and it downloaded. After I reinstalled my OS(with XP) it worked locally but not remotely.
I mean I have the Tomcat running on an XP. I use the same code=.....
I browse http:\\localhost, the page is loaded and so does the applet.
But when browsing http:\\myhostname form a remote machine the status
bar of the page says that the applet class not found.

Please, help!
Thank you!
 
Ulf Dittmer
Rancher
Posts: 42969
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't think you should use an actual URL -including protocol and host name- for the codebase. Try using just the directory name, as is explained here.
 
fedai gandjaliyev
Ranch Hand
Posts: 99
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
DOES NOT HELP.
I have scratched my head until it's raw.
 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24212
35
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Have you tried typing "http://my_host_name/myapplet.class" into the URL bar of a browser on the remote machine? What happens? The precise error message you get could be very useful. Make sure the remote machine's browser is returning the true error page -- using FireFox or another real browser -- or even the appletviewer from the JDK -- would help here; anything is better than using Internet Explorer, which tries hard to hide the real error messages from you.

When you see the real error page when requesting the class file, look at it very carefully, and make sure it's coming from the Tomcat host, and not, for example, from some proxy or firewall in between.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic