Hello,

I tried this by using an iframe in the page that kept refreshing the page. It works but the only problem is you get a click everytime the frame refreshes.

What in javascript would constitute a 'keep alive' request?

I tried images loading etc and they didnt seem to do it.

Thanks,
James

----- Original Message ----- From: "Darren" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <users@tomcat.apache.org>
Sent: Thursday, March 22, 2007 11:19 AM
Subject: Re: Session


I am trying to make the session in my java(Tapestry) project only expire when the browser is closed.

HTTP is stateless so the server has no idea what the client is or isn't doing. You could make something to suit your purposes though;

- change your session timeout to something small like 5 minutes
- at the top of each page add some javascript to make keep-alive style requests to the server every 2 minutes

When the user closes the browser there will be a 5 minute delay and the session will expire on the server.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to