Applet servlet jsp communication

S

sarath

Hi everyone..

i have an applet,which is embedded in the browser, that takes some
input features from user(around 700bytes) and has to contact the
server, with these features. The server then has to process the request
and dispatch to another jsp file whose content will be displayed in the
user browser(not in the applet).

now i am trying to contact the server using Url.openConnection()
method and sending the request to the server.. but the problem is that
the response is obtained by the applet which made the url connection
and not the browser that has the applet embedded.

can any one suggest a way so that the jsp page embedding the
applet will get the response? if you do not understand my question,
please ask me for details..

also , i want to know, if i have and applet, which is embedded in a
jsp file, is it possible to pass parameters to each other ? like, i get
some input from the user in a text field in the applet..is there any
way i can give that value input from the user to the embedding jsp
page(The html code that is generated by the jsp).....

any help would be appreciated..

Thanks in Advance
sarath
 
A

Andrew Thompson

R

Raymond DeCampo

Andrew said:
Send the information as part of a URL in
<http://java.sun.com/j2se/1.5.0/docs/api/java/applet/AppletContext.html#showDocument(java.net.URL)>

But note that you need to have a checking mechanism in the
applet.. Some browsers simply ignore 'showDocument' now due
to the problems with unwanted pop-ups from web pages.
Andrew,

Do you have any details as to which browsers, or pointers to
documentation for this problem?

In particular, I have used URLs of the form "javasrcipt:" in the past, I
am curious if they are affected as well.

Thanks,
Ray
 
T

tex

Which browsers? IE? IE.v6?
Is there another way for my applet to download a 2nd HTML pg
for the user?

Thanks,
--tex
 
A

Andrew Thompson

...
Do you have any details as to which browsers, or pointers to
documentation for this problem?

A discussion[1] (look particularly for Grant Wagner's response)
and browser tester[2]..

[1]
<http://groups-beta.google.com/group/comp.lang.java.programmer/msg/fd45163fc01cdf59>

[2] <http://www.physci.org/codes/showdoc/>

I am afraid that little further detail (as to the exact %
of affected browsers) has become apparent since then.
In particular, I have used URLs of the form "javasrcipt:" in the past, I
am curious if they are affected as well.

Now that is an interesting one. I suspect that if
JS is enabled[3] the JS URL's wold be just as reliable
(or unreliable) as standard showDocument(URL)'s.

[3] But that raises an interesting question I have been
meaning to check.. what happens in a browser that has
JS disabled? Do the JS URL's work at all?

( I am particularly thinking of the Mozilla family
of browsers - if JS is disabled - they are not even
capable of telling you their own program version number! )

BTW - I have been meaning to post a reply to the 'why 1.1?'
thread, but I have so much to say on the subject I am thinking
it should go in a web page (there are a number of applet related
topics that I need to make some commentary on).
[ Including that showDocument() should be considered as unreliable
as showStatus() ever was, and that neither should be used for
vital information. ]

As yet - I have not even had time to read the replies by
Mickey Segal and Tim Tyler.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,022
Latest member
MaybelleMa

Latest Threads

Top