3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php ob_start(); echo 'test'; $sent_a = headers_sent(); @ob_end_clean(); // or ob_clean(); etc.. $sent_b = headers_sent(); var_dump($sent_a); var_dump($sent_b); exit;
based on BS6sh
Output for 5.2.3 - 7.2.0
bool(false) bool(false)
Output for 4.3.0 - 5.2.2
bool(true) bool(true)