[pmwiki-users] automatic logout ?
Ian MacGregor
lists at imacgregor.com
Thu Jul 19 13:47:21 CDT 2007
> Also interesting -- that must be some local default. This means
> that the session will last for 12 hours, or up to the value of
> session.gc_maxlifetime (defaults to 24 minutes).
>
> > As ini_get('session.cookie_lifetime') returns initially nothing,
> > wouldn't it be safer to include in the (farm)config.php)
> > ini_set('session.cookie_lifetime', time() +timeout); ?
>
> At any rate, there's a special-purpose session_set_cookie_params()
> function that seems to do exactly what you want. So, to automatically
> log out after 10 minutes, try (in local/(farm)config.php):
>
> session_set_cookie_params(10 * 60);
For what it's worth, I'm using authuser and neither of the below log me out
after 2 minutes of inactivity:
ini_set('session.cookie_lifetime', time() + 2 * 60);
session_set_cookie_params(2 * 60);
Regards,
Ian MacGregor
>
> Pm
>
> _______________________________________________
> pmwiki-users mailing list
> pmwiki-users at pmichaud.com
> http://www.pmichaud.com/mailman/listinfo/pmwiki-users
More information about the pmwiki-users
mailing list