Board index   FAQ   Search  
Register  Login
Board index php forum :: php coding PHP coding => General

php session suddenly expires on every refresh

Ask about general coding issues or problems here.

Moderators: macek, egami, gesf

php session suddenly expires on every refresh

Postby abeljay10 » Fri Oct 12, 2012 9:12 am

i was working on a code and everything was working well until at some point when i refreshed a page the session just died and i cant believe it
I even tried to refresh a page containing just this
Code: Select all

To make sure none of my codes are messing it up i know if you load and refresh this something is going to show up saying session already started please help
New php-forum User
New php-forum User
Posts: 1
Joined: Fri Oct 12, 2012 8:37 am

Re: php session suddenly expires on every refresh

Postby seandisanti » Fri Oct 12, 2012 10:52 am

refresh of a page with session_start() is not the same as having 2 session_start()'s. also make sure you have a session_start() as the first line passed in every page.
php-forum Fan User
php-forum Fan User
Posts: 838
Joined: Mon Oct 01, 2012 12:32 pm

Return to PHP coding => General

Who is online

Users browsing this forum: Google [Bot] and 3 guests

Sponsored by Sitebuilder Web hosting and Traduzioni Italiano Rumeno and antispam for cPanel.