niranjan81 Posted May 9, 2010 Share Posted May 9, 2010 Can we assign a manual session_id to a user at the second page / level of the website? if yes. could you please suggest a way to do it? server is configured to use cookies and cookies only Link to comment https://forums.phpfreaks.com/topic/201166-how-to-use-session_idmy_session_id-after-the-first-page/ Share on other sites More sharing options...
taquitosensei Posted May 9, 2010 Share Posted May 9, 2010 I'm pretty sure its as easy as. session_start("yourcustomsessionname"); then just use that to start the session at the top of each page that will use it. Link to comment https://forums.phpfreaks.com/topic/201166-how-to-use-session_idmy_session_id-after-the-first-page/#findComment-1055446 Share on other sites More sharing options...
niranjan81 Posted May 9, 2010 Author Share Posted May 9, 2010 Ohh... but sorry for not putting it in the details, but I don't intent to change the session name. I want to set the session_id on the second page, and not first, which means that when on the second page the session is initiated there already is a cookie set to the clients browser belonging to the first session id which will be update with the new session_id but the server side id remains unchanged to the old id, resulting in loss of data collected on the first page. --OR--- if we do session_start("mysessionname"); what about the session data from the first page, how do we reach to it ? Link to comment https://forums.phpfreaks.com/topic/201166-how-to-use-session_idmy_session_id-after-the-first-page/#findComment-1055473 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.