The session checking is done through cookies. The session cookie
(JSessionID)
has to be sent with each request to the web-server. This means that the
applet has to send the same cookie that was sent to the html page.

One solution is to convert the html page into .jsp. Then you can take the
value of the session cookie and send it as a parameter to the applet

something like
<applet ...>
<param name="sessionCookieName" value="JSessionID">
<param name="sessionCookieValue" value='<%=
request.getCookie("JSessionID")'>
</applet>

In the applet,
String cookieValue = getParameter("sessionCookieValue")

and while connecting to the servlet, something like
url.setCookie.. or url.setHeader()





-----Original Message-----
From: A mailing list for discussion about Sun Microsystem's Java Servlet
API Technology. [mailto:[EMAIL PROTECTED]]On Behalf Of Ajay
Bhadauria
Sent: Tuesday, July 24, 2001 8:48 AM
To: [EMAIL PROTECTED]
Subject: Re: Applet - Servlet communication losing session in Netscape


I am using WebLogic App. Server 5.1 (web as well as App. server), but I
think there is no problem regarding Application server settings as in other
part of application , where a servlet is being called from html page, same
session checks work fine in both IE and Netscape.

-----Original Message-----
From: Opoku-Boadu, Samuel [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, July 24, 2001 12:10 PM
To: [EMAIL PROTECTED]
Subject: AW: Applet - Servlet communication losing session in Netscape


What kind of Application Server and Webserver are you using?

-----Urspr�ngliche Nachricht-----
Von: Ajay Bhadauria [mailto:[EMAIL PROTECTED]]
Gesendet: Dienstag, 24. Juli 2001 08:15
An: [EMAIL PROTECTED]
Betreff: Applet - Servlet communication losing session in Netscape


Hi all,
   I am making a browser based application. In this application, an applet
run in a pop-up window which communicate with a servlet and in servlet I am
checking for a valid running session by calling (
request.getSession(false)). It always return NULL  when browser is Netscape
and works fine in IE .
  I am confused . Session is being lost in Netscape becoz the applet is
called in a pop-up window or it is somethig else ?? If there is some problem
with logic, why it is working fine in IE ?
 Can any one throw some light on it.

Ajay

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to