3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php class Pippo { const R = $_SERVER['DOCUMENT_ROOT'] . 'ciao'; } echo Pippo::R;
Output for 5.4.0 - 5.4.15
Parse error: syntax error, unexpected '$_SERVER' (T_VARIABLE) in /in/2Rhvf on line 5
Process exited with code 255.
Output for 5.3.25
Parse error: syntax error, unexpected T_VARIABLE in /in/2s8FJ on line 5
Process exited with code 255.
Output for 5.3.0 - 5.3.24
Parse error: syntax error, unexpected T_VARIABLE in /in/2Rhvf on line 5
Process exited with code 255.