Re: Need a way to automate user logout

From: Date: Sat, 07 Feb 2004 10:04:25 +0000
Subject: Re: Need a way to automate user logout
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-177090@lists.php.net to get a copy of this message
I used cron to do this as well; but i devised a much simpler, elegant solution that is cross-browser and event-based and not schedule-based. I basically have a javascript include file that instantiates a function that counts down in T-minus 10 minutes fashion. at 9:30 the browser pops a window and says "you appear to be inactive; would you like to continue working?" clicking on yes closes the popup and resets the timer; not clicking expires the popout which redirects the parent page to the logout. clicking on "log me out" basically circumvents the 30-second countdown straight to the logout. to handle the alt+F4-happy crowd i devised a way to pop a special logout window when the browser is closed. this child window destroys sessions and makes database logs; this window closes itself. this happened to work for me, YMMV. ~phillip jackson "Craig" <php@lonsbury.com> wrote in message news:IBELIEPEJMOIMBCMOCLJIEEFCIAA.php@lonsbury.com... > > I can write a script in > > perl, php, java, u name it, but how do I have it run on a set > > schedule? > > Thanks > > > > Christian > > you will want to use the cron command. run 'man cron' at a shell prompt > to > get the manual page that will explain the finer points. =) > > HTH, > Craig > > > -- > > PHP General Mailing List (http://www.php.net/) > > To unsubscribe, visit: http://www.php.net/unsub.php > > > >

« previous php.general (#177090) next »