1
In php, Sessions are useful for temporarily holding data. But mine are expiring very fast (in less than 15 minutes) and I still can’t figure out why. Man Session.cache_expire, according to phpinfo() is set to 240.
Thanks in advance.
1
In php, Sessions are useful for temporarily holding data. But mine are expiring very fast (in less than 15 minutes) and I still can’t figure out why. Man Session.cache_expire, according to phpinfo() is set to 240.
Thanks in advance.
1
You have to change the parameter session.cookie_lifetime
more information on PHP website
Update:
Try to increase as well session.gc_maxlifetime
ex.
ini_set('session.gc_maxlifetime', 3600);
session_set_cookie_params(3600);
session_start();
I tried, and you still haven’t solved.
Are you using a Shared host? If so, the folder may be being deleted by the server?
I am, if this is the case the folder is being deleted by the server, what I could do to reverse?
Try creating a custom php.ini and changing the path of Session. Or open a ticket pro support.
I will try, as it is, notify here of what happened. Anyway, thank you very much!
Browser other questions tagged php
You are not signed in. Login or sign up in order to post.
Have you seen if it is set as seconds or minutes? If it is seconds, give 4 minutes... Increase, and take the test
– Sr. André Baill
According to the php.net documentation it is in minutes. And I tested it here and it expires before those 4 minutes, inclusive.
– Cesar de Barros
Tried to increase the time to see?
– Sr. André Baill
I tried now. It didn’t solve.
– Cesar de Barros