3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php class phpinfo1 {} $a = new phpinfo1(); var_dump($a); //$a = 'O:12:"phpinfo();/*":0:{}'; $a = 'O:7:"phpinfo":0:{}'; var_dump(unserialize($a)); var_export(unserialize($a)); //eval('$b = '.var_export(unserialize($a), true).';');
based on hElIo
Output for 5.1.1 - 7.1.0
object(phpinfo1)#1 (0) { } object(__PHP_Incomplete_Class)#1 (1) { ["__PHP_Incomplete_Class_Name"]=> string(7) "phpinfo" } __PHP_Incomplete_Class::__set_state(array( '__PHP_Incomplete_Class_Name' => 'phpinfo', ))
Output for 5.1.0
Fatal error: fatal flex scanner internal error--end of buffer missed in /in/eccCA on line 12
Process exited with code 255.
Output for 5.0.0 - 5.0.5
object(phpinfo1)#1 (0) { } object(__PHP_Incomplete_Class)#1 (1) { ["__PHP_Incomplete_Class_Name"]=> string(7) "phpinfo" } class __PHP_Incomplete_Class { public $__PHP_Incomplete_Class_Name = 'phpinfo'; }
Output for 4.3.0 - 4.4.9
object(phpinfo1)(0) { } object(__PHP_Incomplete_Class)(1) { ["__PHP_Incomplete_Class_Name"]=> string(7) "phpinfo" } class __PHP_Incomplete_Class { var $__PHP_Incomplete_Class_Name = 'phpinfo'; }