Jump to content

[SOLVED] Closing sessions when user closes window??


Perfidus

Recommended Posts

I have a database where I'm storing the sessionID, User, date and 1 or 0 depending if the session is still alive.

I have a function which calculates as well the time an user have been logged and ends the Session after 15 min.

The question is that this function is invoked only  when user's refreshes or moves around the site, this is not a big matter but the real one comes when the user just closes the window or even the browser...

In this case, I would like to know how to set this 1 0 in my DDBB.

 

Maybe some javascript calling a php??

To have this cron that checks for the time the session have already been UP it must be installed on the server, isn't it?

What I mean whit this is: Nothing that can just be uploaded trough FTP but an APP that must self-execute??

I do not have permissions to install anything like this on the server...

I won't worry about it. If you tighten security by closing peoples sessions, you'll just piss them off. I stay logged in to everything, all the time, and hate having to reenter passwords - especially now that FF3 screws up and doesn't save anything properly.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.