Hi,
You can not tell when the session goes away - without them logging out the session is still open on the web server. Which is why you wait 20min because there is no difference to the server if they are active or not.
If they close the browser you can not tell. You potentially could build something in ajax that is constantly sending messages back to your server - a keep alive if you will, then have something on your back end to clean up everything that has not sent a keep alive for a certain period. But I'm not sure how reliable that would be.
Main Topics
Browse All Topics





by: HuyBDPosted on 2006-10-29 at 22:28:00ID: 17831964
Try to use isset($_SESSION["order_id" ]) to detect variable in session _id"]))
if(!isset($_SESSION["order
do smt....