jeremyhowell Posted December 14, 2009 Share Posted December 14, 2009 I want to keep people from opening multiple tabs, or sessions of my Facebook app. Is it possible to check if a session is currently running of my app, like maybe using a cookie or something? Quote Link to comment https://forums.phpfreaks.com/topic/185030-check-if-another-session-of-the-page-is-running/ Share on other sites More sharing options...
mikesta707 Posted December 14, 2009 Share Posted December 14, 2009 you could just use sessions, and check if one is set if (isset($_SESSION['whatever'])){ //they are already viewing } But that may lead to unwanted results. For example, if you have that check doing something like if (isset($_SESSION['var'])){ //don't let the user play } else { //let them play } then if the user refreshes the page, they won't be able to play again until they close the connection to the server (IE closing the page/browser) Quote Link to comment https://forums.phpfreaks.com/topic/185030-check-if-another-session-of-the-page-is-running/#findComment-976703 Share on other sites More sharing options...
jeremyhowell Posted December 14, 2009 Author Share Posted December 14, 2009 Okay, thanks you. Quote Link to comment https://forums.phpfreaks.com/topic/185030-check-if-another-session-of-the-page-is-running/#findComment-976706 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.