Re: session and expiration function

From: Date: Tue, 24 Sep 2002 03:26:24 +0000
Subject: Re: session and expiration function
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-117361@lists.php.net to get a copy of this message
thanks.. i will check it out "John Holmes" <holmes072000@charter.net> wrote in message news:002601c26378$b4189350$b402a8c0@mango... > Just use ini_set() to set a different session.save_path() than what's in > your PHP.ini. then the garbage collector won't touch it. Write your own > script to do the deleting and call whatever functions you need. Add that > to your cron script to run every hour or day, and you're good to go. You > made your own garbage collector. > > I'm going to have to do this for a sourceforge site I have. I started a > thread about this on the PHP board at Devshed and someone posted a > sample function to handle the cleanup. > > ---John Holmes... > > > -----Original Message----- > > From: christian haines [mailto:christian@mitousa.com] > > Sent: Monday, September 23, 2002 11:06 PM > > To: php-general@lists.php.net > > Subject: Re: [PHP] session and expiration function > > > > thanks john, > > > > hmmm... i suspected as much... > > > > i guess the way to do it would be to set a highly improbable garbage > > collection and long timeout via ini_set. then use a timeout function > > attached to the session which launches on expiration > > > > cheers > > christian > > > > "John Holmes" <holmes072000@charter.net> wrote in message > > news:002501c26374$e136db20$b402a8c0@mango... > > > > is it possible to have a function execute when a session expires > using > > > > php4 > > > > sessions? > > > > i know how to execute a function if i control the timeout (as > > > mentioned > > > > elsewhere in this group) but what about if the session times out > > > itself > > > > using the inbuilt garbage collection routine. > > > > if so, any ideas how? > > > > > > I don't think there's a way to do it besides hacking the source > code. If > > > you really have to do this, I'd set your own session.save_path() in > your > > > scripts and then write a script to do the cleanup and function > calling > > > for you. > > > > > > ---John Holmes... > > > > > > > > > > > -- > > PHP General Mailing List (http://www.php.net/) > > To unsubscribe, visit: http://www.php.net/unsub.php >

« previous php.general (#117361) next »