I am trying to set gc_maxlifetime in PHP.
Here is the code in 'header.php', and I include it every page.
ini_set('session.cookie_lifetime', 1);
ini_set('session.gc_maxlifetime', 1);
session_start();
I test it with
echo ini_get('session.gc_maxlifetime');
and it does set to 1.
But it still keep login status, that is, session has not been deleted.
What is the possible reason?