Jump to content

PHP Session Duplication


Emesh

Recommended Posts

I've recently had a problem with my admin site where PHP sessions, which are stored in a MySQL database, are duplicating and causing the page to return to the login screen.  Usually the site works fine in Firefox, but stops working in IE and Safari.  This problem suddenly appeared over night with no change to the files. 

 

Due to the amount of code, I'm reluctant to post it all, but does anyone have a suggestion on why this could be happening and how to solve it? 

Link to comment
Share on other sites

Honestly without looking at the code its literally just guessing... you need to write some functions to debug your code. Like start building functions that make you an error log.

Link to comment
Share on other sites

<!DOCTYPE html> has nothing to do with PHP. As you're using sessions I guess you have written your own session handler for saving your sessions to the database. When you call session_start() to create a session make sure you calling that function before any html has been sent to the web browser. If you call it after html has been sent session will no longer work.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.