3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php var_dump(unserialize('O:8:"DateTime":3:{s:4:"date";s:19:"1970-01-01 00:00:00";s:13:"timezone_type";i:1;s:8:"timezone";s:6:"+01:00";}'));
based on GDHEr
Output for 5.4.30 - 5.4.45, 5.5.14 - 5.6.28, 7.0.0 - 7.1.0
object(DateTime)#1 (3) { ["date"]=> string(26) "1970-01-01 00:00:00.000000" ["timezone_type"]=> int(1) ["timezone"]=> string(6) "+01:00" }
Output for hhvm-3.10.0 - 3.13.2
Fatal error: Uncaught exception 'Exception' with message 'DateTimeZone::__construct(): Unknown or bad timezone (+01:00)' in /in/HDkRW:3 Stack trace: #0 /in/HDkRW(3): DateTime->__wakeup() #1 {main}
Process exited with code 255.
Output for 5.2.0 - 5.4.29, 5.5.0 - 5.5.13
object(DateTime)#1 (3) { ["date"]=> string(19) "1970-01-01 00:00:00" ["timezone_type"]=> int(1) ["timezone"]=> string(6) "+01:00" }
Output for 5.0.0 - 5.1.6
object(__PHP_Incomplete_Class)#1 (4) { ["__PHP_Incomplete_Class_Name"]=> string(8) "DateTime" ["date"]=> string(19) "1970-01-01 00:00:00" ["timezone_type"]=> int(1) ["timezone"]=> string(6) "+01:00" }
Output for 4.3.0 - 4.4.9
object(__PHP_Incomplete_Class)(4) { ["__PHP_Incomplete_Class_Name"]=> string(8) "datetime" ["date"]=> string(19) "1970-01-01 00:00:00" ["timezone_type"]=> int(1) ["timezone"]=> string(6) "+01:00" }