jdlev Posted October 9, 2009 Share Posted October 9, 2009 For whatever reason, session_regenerate_id() screwed up my authentication system in php. If I remove session_regenerate_id(), it works just fine, and creates 1 session file that contains data in the temp folder. If I leave session_regenerate_id() in there, it produces 2 session files after login, and won't allow access to the secured areas - it says authenticaion denied. Of the 2 session files it produces, one has data in it which is correct. The other has no data in it. There's not really any code, and I've never used session_regenerate_id() before so I'm not sure if I'm using the wrong syntax? Basically, what happens is that there is an if statement where if the user's name & password are found in the database, it regenerates the session id...so it's basially like this: if(user in database & password good) { session_regenerate_id(); } Link to comment https://forums.phpfreaks.com/topic/177040-session_regenerate_id-troubles/ Share on other sites More sharing options...
ohdang888 Posted October 9, 2009 Share Posted October 9, 2009 is it throwing any errors? Link to comment https://forums.phpfreaks.com/topic/177040-session_regenerate_id-troubles/#findComment-933460 Share on other sites More sharing options...
jdlev Posted October 9, 2009 Author Share Posted October 9, 2009 is it throwing any errors? I haven't seen any...do I need to enable anything in the php.ini file in order to see some errors that I might be missing? Link to comment https://forums.phpfreaks.com/topic/177040-session_regenerate_id-troubles/#findComment-933800 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.