Session is lost after some time around 25 minutes

Viewed 584

I am using PHP 5.5.38 on apache server 2.4.16. I get this problem of losing the session after sometime (around 25 mins). I found these parameters in php.ini file

session.gc_maxlifetime = 1440
session.gc_probability = 10

But in the code these has been setting up to different values. The code looks like this

ini_set('session.gc_maxlifetime', 60*60*24*7);
ini_set('session.use_cookies', 1);
ini_set('session.gc_probability', 0);

and i confirmed them returning the older values which means its not failing or something.

I don't know where else to look to find the cause of losing the session. Any idea or suggestion would be greatly appreciated.

1 Answers
Related