note 40422 deleted from function.register-shutdown-function by nlopess

From: Date: Wed, 03 Mar 2004 17:41:35 +0000
Subject: note 40422 deleted from function.register-shutdown-function by nlopess
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-66189@lists.php.net to get a copy of this message
Note Submitter: James Wyse (James[at]tastyspoon[dot]com) ---- I've been having problems where my script will continue to load in the browser until the shutdown function is complete, this seems to fix that // make sure headers get sent right away if(ini_get('zlib.output_compression')) ini_set('zlib.output_compression', 'Off'); if(ini_get('output_buffering')) ini_set('output_buffering', '0'); // tell browser there was no response, should close the connection header("HTTP/1.0 204 No Response"); // flush any output and register our function flush(); register_shutdown_function('function'); any comments or suggestions appreciated :)

« previous php.notes (#66189) next »