3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $metadata = array('test' => 'test'); $test = var_export(serialize($metadata), true); $test2 = unserialize($test); $eval = 'return unserialize('.serialize($metadata).');'; echo eval($eval);
based on DAtSD
Output for 7.3.0alpha1
Notice: unserialize(): Error at offset 0 of 30 bytes in /in/pHUaY on line 4 Parse error: syntax error, unexpected ':', expecting ')' in /in/pHUaY(7) : eval()'d code on line 1
Process exited with code 255.
Output for 7.0.0 - 7.2.6
Notice: unserialize(): Error at offset 0 of 30 bytes in /in/pHUaY on line 4 Parse error: syntax error, unexpected ':', expecting ',' or ')' in /in/pHUaY(7) : eval()'d code on line 1
Process exited with code 255.
Output for hhvm-3.15.4
Notice: Unable to unserialize: ['a:1:{s:4:"test";s:4:"test";}']. Expected ':' but got 'a'. in /in/pHUaY on line 4 Fatal error: syntax error, unexpected ':', expecting ')' in /in/pHUaY(7)(14a9c8b3ed78a0ddc48d69d1a7a8513a) : eval()'d code on line 1
Output for 5.6.0 - 5.6.30
Notice: unserialize(): Error at offset 0 of 30 bytes in /in/pHUaY on line 4 Parse error: syntax error, unexpected ':' in /in/pHUaY(7) : eval()'d code on line 1