jaymc Posted January 12, 2007 Share Posted January 12, 2007 If i set the session cookie to expire in 30 minutes rather than when the browser is closed, does that mean from the moment they login they will loose their session in 30 minutesOr, is it 30 minutes after they have stopped viewing pagesIn otherwords, everytime the view a page does that start the 30 min countdown again? Quote Link to comment Share on other sites More sharing options...
taith Posted January 12, 2007 Share Posted January 12, 2007 30 min from the last session_start(); which should be at the top of all your doccuments Quote Link to comment Share on other sites More sharing options...
jaymc Posted January 12, 2007 Author Share Posted January 12, 2007 Is that the best way to do it?Because on my site the sessions are dying randomlyIm just wondering if for some reason the browser thinks its been closedThe solution though could be to set session expire time to 30 minutes..However, what happens if someone closes the website and then their friend opens it again in 15 minutes timeEssentially, they will then be logged in as them, right?Thats what im worried about Quote Link to comment Share on other sites More sharing options...
taith Posted January 12, 2007 Share Posted January 12, 2007 no... sessions are tied to the browser itself... so if the user closes his browser, the session dies... however if your using a browser with tabs, closing a tab, will not kill the session. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.