Re: escape loop on timeout

From: Date: Tue, 22 May 2001 09:41:06 +0000
Subject: Re: escape loop on timeout
References: 1  Groups: php.windows 
Request: Send a blank email to php-windows+get-7809@lists.php.net to get a copy of this message
This is a way of doing it: $s = time() + 10; for ($i = time(); $i <= $s; $i++) { print $i; } Will run for about ten seconds... /Johan Brendan Gogarty wrote: > > hi, > just wondering if there was any easy way to break/escape from a loop > (for loop) if the loop exceeds a maximum time. > I realise that set_timeout applies to the whole script but i am just > interested in a sub function of the script. > > cheers! > brendan. > > -- > PHP Windows Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-windows-unsubscribe@lists.php.net > For additional commands, e-mail: php-windows-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.windows (#7809) next »