3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php /* $values['test']['radio'] = "foo']) OR die('RCE');"; $myVar = "['test']['radio']"; eval("\$x = (isset(\$values$myVar)) ? \$values$myVar : 'failed';"); print_r($x); */ $val = '"test"; echo "hacked code running";'; eval("\$x = isset($val) ? $val : 'fail'");
based on PHXsR
Output for 7.3.0alpha1 - 7.3.0beta1
Parse error: syntax error, unexpected ';', expecting ')' in /in/gjRpq(12) : eval()'d code on line 1
Process exited with code 255.
Output for 7.0.30 - 7.2.8
Parse error: syntax error, unexpected ';', expecting ',' or ')' in /in/gjRpq(12) : eval()'d code on line 1
Process exited with code 255.
Output for hhvm-3.22.0
Fatal error: syntax error, unexpected ';', expecting ',' or ')' in /in/gjRpq(-1)(d93a5e6b6ad4a53cdb4400881ac9dae2) : eval()'d code on line -1
Output for hhvm-3.18.5 - 3.21.3
Fatal error: syntax error, unexpected ';', expecting ',' or ')' in /in/gjRpq(12)(d93a5e6b6ad4a53cdb4400881ac9dae2) : eval()'d code on line 1
Output for 5.6.30
Parse error: syntax error, unexpected ';' in /in/gjRpq(12) : eval()'d code on line 1