Regarding Session reset

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View

This is Nitin here,I want to reset the session variables as soon
browser got refresh. if any one knows how to do that. please guide me.



Re: Regarding Session reset

On Fri, 05 Aug 2011 08:08:47 -0700, Nitin wrote:

Quoted text here. Click to load it

You can't do this reliably.

The best you can do is use session expiry times on the server.

You can *try* and use an onunload event handler in the page to trigger a
call to a url that will reset the session variables, but if the client
computer is disconnected from the network before the page is unloaded it
has no way to handle the event - for example a wifi connected system
where the signal drops and then the user closes the browser.

The only way to catch this is expiring the session on the server after a
predetermined amount of inactivity.


Denis McMahon

Re: Regarding Session reset

On 8/5/2011 12:01 PM, Denis McMahon wrote:
Quoted text here. Click to load it

I'm not smart enough to know if this is a good or reliable way to do it.

Search the page for "browser refresh". The contributor offers a function
to do such a thing (at least as I read it).

Bill B

Site Timeline