Does die () do ob_end_flush ()?

I cannot find a good answer to this anywhere. If I start output buffering and die() starts, does it start ob_end_flush() ?

+6
php output-buffering die
source share
1 answer

Yes Yes. Each time the script finishes gracefully, the buffers will be empty. The only non-elegant endings are: if he segments errors or if he was killed (signal 9 SIG_KILL). The only place where die() performs a hard kill on a process is to call it inside register_shutdown_function (But the buffers are cleared before the shutdown function is turned off, so there is no problem). See "Handling Connections" for more information ...

+12
source share

All Articles