Jump to content

SESSION STARTED PHP HELP


willo2k13

Recommended Posts

im trying to learn php and when i was installing openbooking i got it instaled and when i type the username and password in it just says Notice: A session had already been started - ignoring session_start() in c:\program files\easyphp1-8\www\system\session.php on line 2 does anyone know how i can get round this

 

thanks craig

 

Link to comment
https://forums.phpfreaks.com/topic/49813-session-started-php-help/
Share on other sites

session_start() can only be called once (obviously if it is already started you cannot start it again).  I have not used the specific application you refer to, however it is likely that you are using an include() or require() directive that contains another session_start() command or your PHP settings are such that a session is automatically started for every page.  You can get some more info here:

http://us.php.net/manual/en/ref.session.php#ini.session.auto-start

 

Certainly the "short answer" is to comment out line 2 in session.php...but that is probably NOT a good idea.  More likely, look at the actual page url that you have loaded (whatever your browser's address bar days when you have the error) and read the code of that php file.  Comment out the session_start() line on that file so that your session.php file can hangle your entire session (i don't know what that file does exactly, but this was a guess based on teh filename).

 

Hope this helps.

  • 4 weeks later...

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.