[PHP] timer in php-cli

2004-03-01 Thread nobody
Hello, I'm writing a php irc bot. I've come up to the situation where I need a timer for processing different data in a "special" way. I've searched the archive of the list but I didn't found nothing helpful (I can't use JavaScript here, neither cron). If I use for(;;) or sleep(); the whole scrip

Re: [PHP] timer in PHP

2001-04-11 Thread Plutarck
I'm guessing it's either for a Quiz script or an Auction script. If you want to make it easy on yourself, use a database to store the starting time (when the timer "starts") and what time the test/auction should end. When someome makes a submission, get the time stored in the database and see if

Re: [PHP] timer in PHP

2001-04-11 Thread Chris Lee
there is no sure way, but using cookies/sessions you can make something that will *work* . assign the user a session_id, every time the user makes an entry add a value to the db, session_id = $SessionID next_time = time() + 120 every time you make an entry, check to make sure that next_time <

[PHP] timer in PHP

2001-04-11 Thread george
I need to have a time running and after a certain time it will not allow you to submit anything else, on top of that if someone makes an entry with less than 2 minutes to go the time must be extended by 5 minutes. I really am at a loss how to do this. Can it be done. TIA George -- PHP Ge