From: Andrew Dolgov Date: Thu, 2 Mar 2006 16:21:08 +0000 (+0100) Subject: SESSION_COOKIE_LIFETIME X-Git-Tag: schema_freeze_for_1.1.4~25 X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=686c3ccfa6060be0b3ed2a634709bb7eff702f50;p=tt-rss.git SESSION_COOKIE_LIFETIME --- diff --git a/config.php-dist b/config.php-dist index 17b2ed53..8baf4b76 100644 --- a/config.php-dist +++ b/config.php-dist @@ -107,5 +107,8 @@ define('SESSION_CHECK_ADDRESS', true); // Bind sessions to specific IP address (requires DATABASE_BACKED_SESSIONS) + define('SESSION_COOKIE_LIFETIME', 3600); + // In seconds, 0 means delete on browser close + // vim:ft=php ?> diff --git a/sessions.php b/sessions.php index 36a982f7..42877ffe 100644 --- a/sessions.php +++ b/sessions.php @@ -107,6 +107,8 @@ db_query($session_connection, $query); } + session_set_cookie_params(SESSION_COOKIE_LIFETIME); + if (DATABASE_BACKED_SESSIONS) { session_set_save_handler("open", "close", "read", "write", "destroy", "gc"); }