This week's book giveaway is in the OCMJEA forum.
We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line!
See this thread for details.
The moose likes Applets and the fly likes Please help: AppletContext.showDocument, yet servlet reports different url Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Java » Applets
Bookmark "Please help: AppletContext.showDocument, yet servlet reports different url" Watch "Please help: AppletContext.showDocument, yet servlet reports different url" New topic
Author

Please help: AppletContext.showDocument, yet servlet reports different url

Ken Flor
Ranch Hand

Joined: Aug 01, 2006
Posts: 34
Please help me.
Sigh .. this is driving me insane.


I have an applet that does a showDocument to a Servlet.

The code is :

this.getAppletContext().showDocument(url, "Report");

the url is the path and the "Report" is the name of the frame.


However in my servlet when i did a getRequestURL, the url reported is different. Why is that so?

Since the servlet can be loaded successfully from the applet.showDocument, how come the url reflected is wrong?


How can i get back the original url with the path?

Thanks.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41634
    
  55
What is the URL you're requesting in the applet, and which one is returned by getRequestURL?


Ping & DNS - my free Android networking tools app
 
Don't get me started about those stupid light bulbs.
 
subject: Please help: AppletContext.showDocument, yet servlet reports different url