Session dies in CodeIgniter
I have an app built in CI and I would like that sessions don't die unless users close their browser. In my config file I have the following:
$config['sess_cookie_name'] = 'ci_session';
$config['sess_expiration'] = 0;
$config['se开发者_StackOverflow中文版ss_encrypt_cookie'] = FALSE;
$config['sess_use_database'] = FALSE;
$config['sess_table_name'] = 'ci_sessions';
$config['sess_match_ip'] = FALSE;
$config['sess_match_useragent'] = TRUE;
$config['sess_time_to_update'] = 0;
But session still dies after a period of time, is there any other configuration I need to do? Maybe directly on the server that might be causing the session to die? Thanks!
http://www.php.net/manual/en/session.configuration.php#ini.session.gc-maxlifetime
by default, PHP sessions are garbage collected after 24 minutes.
精彩评论