aliento Posted April 7, 2013 Share Posted April 7, 2013 Hi, I have problem with sessions , when i change from no subdomain qip.gr to www.qip.gr it doesn't hold the sessions. Is there any solution ? Thank yu Quote Link to comment https://forums.phpfreaks.com/topic/276650-same-_session-different-sub-domain/ Share on other sites More sharing options...
requinix Posted April 8, 2013 Share Posted April 8, 2013 Cookies were originally designed (unintentionally) so that it's not possible: www.qip.gr cannot set a cookie for "qip.gr", and while it can set one for ".qip.gr" the no-subdomain site couldn't read that. Force one or the other on your site - don't allow both. Which is a best practice anyways. Quote Link to comment https://forums.phpfreaks.com/topic/276650-same-_session-different-sub-domain/#findComment-1423544 Share on other sites More sharing options...
remenissions Posted April 8, 2013 Share Posted April 8, 2013 (edited) You could probably store the data in a database and read the session data that way. Edited April 8, 2013 by remenissions Quote Link to comment https://forums.phpfreaks.com/topic/276650-same-_session-different-sub-domain/#findComment-1423548 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.