3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?phpob_end_clean();header("Connection: close");ignore_user_abort(); // optionalob_start();echo ('Text the user will see');$size = ob_get_length();header("Content-Length: $size");ob_end_flush(); // Strange behaviour, will not workflush(); // Unless both are called !// Do processing heresleep(10);echo('Text user will never see');
Output for 7.0.0 - 7.1.0
Fatal error: Uncaught Error: Call to undefined function phpob_end_clean() in /in/7DmnA:1 Stack trace: #0 {main} thrown in /in/7DmnA on line 1
Process exited with code 255.
Output for hhvm-3.10.0 - 3.12.0
Fatal error: <?php directive must be followed by whitespace, newline, or EOF (Line: 1, Char: 5) syntax error, unexpected T_HH_ERROR, expecting $end in /in/7DmnA on line 1
Process exited with code 255.
Output for 5.4.34 - 5.6.28
Fatal error: Call to undefined function phpob_end_clean() in /in/7DmnA on line 1
Process exited with code 255.
Output for 4.3.0 - 5.4.32
<?phpob_end_clean();header("Connection: close");ignore_user_abort(); // optionalob_start();echo ('Text the user will see');$size = ob_get_length();header("Content-Length: $size");ob_end_flush(); // Strange behaviour, will not workflush(); // Unless both are called !// Do processing heresleep(10);echo('Text user will never see');