This page contains an archived post to the Java Answers Forum made prior to February 25, 2002.
If you wish to participate in discussions, please visit the new
JavaServlets and Applet communication!
Posted by Anu on May 25, 2001 at 12:53 PM
I have problems with making my applet communicate with the servlet.
Here is the directory structure:
|_ startserver ( web server )
In the applet.html file, I am loading the applet ,appletEg.class.
appletEg.class connects to the URL http:/localhost:8080/examples/servlet/RetFileServlet
and retrieves the information it gives and shows it in the applet.
In the applet.html
I have this,
"applet code="appletEg.class" codebase="../examples/WEB-INF/servlets/" width = 800 height = 400>
(I have removed the <> , because it was actually showing applet
instead of text)
This works fine when I run
But when I try to see the applet in the browser,
it gives me an error: Applet appletEg can't start:ERROR.
But for my project which is web application I should be able to see it
in the browser.
I need help ASAP, Its my project work and I dont know
whats the problem. Am an amatuer.
Could anybody help me with this!
Thanks in advance