Hi
is it possible to define a fixed time for which a session will stay active for? At the moment my sessions expire too frequently and is annoying users a bit !
Thanks
Session expiration
Moderator: General Moderators
It may be the session.cache_expire setting in your PHP.ini (it defaults to 180), so try changing that. If you don't have access to the PHP.ini you can use:
At the top of every page, before session_start(), to set the cache expire for 180 minutes.
Code: Select all
<?php
session_cache_expire(180);
?>