Page 1 of 1
session time.
Posted: Thu Feb 12, 2004 7:34 pm
by d3ad1ysp0rk
Sorry but I couldn't find it on php.net (
http://us2.php.net/session ) at all..
I did it before, but I just can't remember the syntax.
How do I set a session that gets deleted in say, a second?
and is it possible to do fractions of a second?
Posted: Thu Feb 12, 2004 7:42 pm
by markl999
ini_set('session.cookie_lifetime', '1'); ?
Not sure about fractions of a second (doubt it), but you can try

Posted: Thu Feb 12, 2004 7:52 pm
by d3ad1ysp0rk
hmm.. i mean i want my var to go away in x amount of time..
something like
$_SESSION['var'] = "value", time;
or w/e
Posted: Thu Feb 12, 2004 7:53 pm
by markl999
Well ini_set('session.cookie_lifetime', '1'); will basically delete the session after 1 second, or do you just want to expire some of the session variables after a certain time? If so, that's slightly trickier.
Posted: Thu Feb 12, 2004 9:46 pm
by d3ad1ysp0rk
ya i do
but i realized my mistake
cookies use times to destroy themselves after x amount of time..
thanks for the help anyways
Posted: Thu Feb 12, 2004 10:21 pm
by tim
perhaps you are thinking of the:
You can only set it in minutes that I know of...