[PHP] Catch timeouts

2001-03-20 Thread CC Zona

I'm resetting set_time_limit() with each iteration of a rather long loop.  
Right now when the script reaches its time limit I sometimes end up getting 
just a blank page.  Even though I call flush() within each iteration and do 
lots of error checking along the way, it seems to not be enough.  

I could have sworn I once saw a function that would check whether the 
script was being cancelled because a timeout had occured, thereby allowing 
you to make a more graceful exit from the script.  But now I can't seem to 
locate anything like that in the manual. If someone could point me to the 
right function, or suggest an alternative method for catching those 
timeouts, I would be grateful.

TIA!

-- 
CC

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Catch timeouts

2001-03-20 Thread CC Zona

In article 998dqa$akd$[EMAIL PROTECTED],
 [EMAIL PROTECTED] (CC Zona) wrote:

 I could have sworn I once saw a function that would check whether the 
 script was being cancelled because a timeout had occured, thereby allowing 
 you to make a more graceful exit from the script.  But now I can't seem to 
 locate anything like that in the manual.

Never mind.  Found it: connection_timeout() and 
register_shutdown_function().  Perfect.

-- 
CC

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]