3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function test(string str){ if(strpos(str, ">") !== false) { $exp = explode(">", str); return ($exp[0] > $exp[1]); } } var_dump(test("1.2 > 2"));
Output for 5.4.0 - 5.4.26
Parse error: syntax error, unexpected 'str' (T_STRING), expecting '&' or variable (T_VARIABLE) in /in/qlYoH on line 3
Process exited with code 255.
Output for 5.3.0 - 5.3.28
Parse error: syntax error, unexpected T_STRING, expecting '&' or T_VARIABLE in /in/qlYoH on line 3
Process exited with code 255.