lark Posted September 8, 2006 Share Posted September 8, 2006 I have a site that uses sessions for user logins. It works fine as long as the user stays in the domain from which they logged in. But if they switch at some point between just the domain mydomain.com to www.mydomain.com (or vice-versa), the session is lost. Is there a workaround for this?Thanks! Quote Link to comment https://forums.phpfreaks.com/topic/20150-question-about-sessions-persisting-across-domains/ Share on other sites More sharing options...
phporcaffeine Posted September 8, 2006 Share Posted September 8, 2006 You need to look at the gpc_max_lifetime in the .ini file because the session shouldn't die just because you navigate from the domain to another domain, UNLESS you have your gpc_max_lifetime set to do so. Quote Link to comment https://forums.phpfreaks.com/topic/20150-question-about-sessions-persisting-across-domains/#findComment-88605 Share on other sites More sharing options...
lark Posted September 8, 2006 Author Share Posted September 8, 2006 It doesn't die. If you go back to the domain you logged in from, the session is still there. It just doesn't communicate between mydomain.com and www.mydomain.com Quote Link to comment https://forums.phpfreaks.com/topic/20150-question-about-sessions-persisting-across-domains/#findComment-88606 Share on other sites More sharing options...
lark Posted September 22, 2006 Author Share Posted September 22, 2006 Any thoughts on this one? Quote Link to comment https://forums.phpfreaks.com/topic/20150-question-about-sessions-persisting-across-domains/#findComment-96887 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.