Hello Heiko,
I think you're looking for the following method:
javax.servlet.http.Cookie#setMaxAge(int expiry)
Its default value (see getMaxAge()) is -1 => the cookie persists until
browser shutdown.
Regards,
Dies
Heiko Klein wrote:
Hi,
I'm currently moving an web-application from custom-made to
tomcat-servlet. Before, I used my own cookie management to store
user-preferences. The cookies had a persistence on the browser of 1
year, if the browser-configuration allowed that.
The default tomcat cookies for session-management seem to be deleted
with browser-restart. How can I keep a session open even if the user
restarts his computer? Or in other words, how can I set the 'Expires'
field of the session-cookie send to the browser?
Best regards,
Heiko
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]