Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Applet to Servlet session problem  RSS feed

 
Kalluru Uma
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,
I have a JSP page with an applet in it. The applet talks to a Servlet. The session object that is present in my JSP page is not accessable in my servlet.
How can I get the session object from my JSP page to the Servlet through an Applet?
Thanks
Uma
 
Chris Stehno
Ranch Hand
Posts: 180
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
First of all, I think you need to give a little more information... like why cant you access the session in your servlet (are they on different servers or something?), and what kind of data are you trying to transfer...
If your problem is that you dont know how to get access to the session in a servlet, then in the request processing method, try
request.getSession()
You probably dont need to transfer the entire session object, just a few attributes.
 
wally fer
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
you can use ServletContext to communicate with other servlet in the container.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!