Mau:
When you lose the session, is the window you're opening coming up in a new
window? Depending on the browser, that can make odd things happen with
sessions.
Any different with different browsers?
Mike
Javacorporate Ltd
http://www.javacorporate.com
-----Original Message-----
From: A mailing list for discussion about Sun Microsystem's Java Servlet
API Technology. [mailto:[EMAIL PROTECTED]]On Behalf Of
Emmanuel JEGOU
Sent: Thursday, September 02, 1999 6:04 AM
To: [EMAIL PROTECTED]
Subject: session lost without warning
Hello,
I use servlets and on my web pages I need authentication, so I need to
have a session. But, I used do it with the
httpServletRequest.getSession(false) to see if there was an existing
session and if the result is null then I do
httpServletRequest.getSession(true) to create a new session. The problem
is a great one. It used to work and now it doesn't work anymore :-(. I
didn't touch anything, so I don't know how to do !
I tried httpServletRequest.isRequestedSessionIdValid() to see if a
session exists and httpServletRequest.getSession(true) to create a
session if doesn't exist but everything failed :-((((
When I use a debugger to see where the problem come from, I can see that
the time I look for a session, it doesn't exist and then a popup window
came in my browser to ask me to accept the cookie. I accept, then the
servlet is launched again and when in the servlet code I look for the
session, it exist. Then (I have an authentication page) I valid my
authentication and the servlet is launched again and here, the session
doesn't exist anymore !
I don't know how to do it, please help me.
Thanks in advance, Manu.
configuration : JSDK 2.1 running with VisualAge 2.0 ; Netscape
enterprise Server or Apache : the result is the same !
___________________________________________________________________________
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