I did an AJAX version of this a couple of months ago.
The slight gotcha is that the AJAX request prolongs the life of the session (you can't, it seems, override the cookie for AJAX requests) so the interval has to be slightly longer than the expiry time for the session.

Reynir Hubner wrote:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,
I would suggest that you do this by using somethinglike JSON or AJAX.
See jasonspec: http://www.crockford.com/JSON/index.html

You could make the client query your server, in some interval and check
the session state.

hope it helps
- -reynir



Mark wrote:

Is there any way to allow servlets to auto-logout a user when the timeout
has been reached. Right now, I have tomcat configured for a 20 minute
session timeout. When the session times out, the user gets no notification
of this event. Is there any way to show the user that they have logged out?

Thank you.


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.5 (MingW32)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFDeeqn19KgIQihNwgRAqT8AJ9ijf9kZZlldgjRTcAEtua+89enKQCgnqjm
iuCZACbq4A/JkmtB5yiIc8M=
=HSCq
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to