s0c0 Posted February 11, 2008 Share Posted February 11, 2008 Is this possible? A client of mine has CMS on domain1.com and a seperate one for domain2.com. I am developing the CMS for domain2 and have made the sessions look the same to facilitate easily moving between the two. Can I pass the session id through a url or post if they are on the same server? Do I need to instead use a cookie? Or is this impossible. Thanks. Quote Link to comment https://forums.phpfreaks.com/topic/90472-passing-sessions-between-domains-on-the-same-server/ Share on other sites More sharing options...
jojo80 Posted February 11, 2008 Share Posted February 11, 2008 I think this is possible, you need to use session_set_save_handler to save your sessions to a database pass session id to the other domain and retrieve session details from the database but you should be careful regarding security, if you pass session id this way it will be easy to hijack your sessions. so extra checks are necessary(IP address, client agent, etc) Quote Link to comment https://forums.phpfreaks.com/topic/90472-passing-sessions-between-domains-on-the-same-server/#findComment-463849 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.