Hi Wen I close the browser without logging out of my site and then again open the browser & redirect it to my site the user is already logged in.?? Is it not so that the sessions are destroyed when one closes the browser without logging out?? Or I have to handle this?
nohting to do man..it works likes that
didnt get u fred is this the normal behaviour? if yes what shud i do??
Setting the session cookie lifetime to 0 means the session ends when the browser is closed.
Nyet; sessions end when the browser is closed anyway. The "session lifetime" is how long the server should wait before session data is considered "garbage" and a candidate for deletion.
Heh never knew that, I assumed that this board's session lifetimes were set to some large amount hence why you don't get logged out. Must be some other method I guess.
Here's a hack/workaround, from the manual user notes:
<?php session_start(); session_write_close(); session_set_cookie_params([TTL in seconds]); session_start(); // Continue using sessions as normal ?>