note 68728 modified in function.session-cache-expire by bobby

From: Date: Tue, 26 Sep 2006 01:51:40 +0000
Subject: note 68728 modified in function.session-cache-expire by bobby
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-117670@lists.php.net to get a copy of this message
you can change the max lifetime for a session with the function ini_set(). <?php ini_set("session.gc_maxlifetime", "18000"); ?> This will set the max lifetime of the script to 5 hours. You have to use this in every script that you want to change the default lifetime for. if you want to know the lifetime of your current script, you can use: <?php echo ini_get("session.gc_maxlifetime"); ?> --was-- you can change the max lifetime for a session with the function ini_set(). <?php ini_set("session.gc_maxlifetime", "18000"); ?> This will set the max lifetime of the script to 5 hours. You have to use this in every script that you want to change the default lifetime for. if you want to know the lifetime of your current script, you can use: <?php echo ini_set("session.gc_maxlifetime"); ?> http://php.net/manual/en/function.session-cache-expire.php

« previous php.notes (#117670) next »