3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php ob_start(); function level(){ public function level2(){ echo 'Text that won\'t get displayed.'; } } level('level2'); echo "\n"; var_dump(ob_get_level()); ?>
Output for 5.4.0 - 5.4.21
Parse error: syntax error, unexpected 'public' (T_PUBLIC) in /in/P1QO0 on line 4
Process exited with code 255.
Output for 5.3.0 - 5.3.27
Parse error: syntax error, unexpected T_PUBLIC in /in/P1QO0 on line 4
Process exited with code 255.