3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php echo ("Expires: ".gmdate("D, d M Y H:i:s", time() + 3600)." GMT"); echo '\n\n'; $expirytime=new DateTime("D, d M Y H:i:s O"); echo $expirytime;
based on 5EeH2
Output for 7.0.0 - 7.2.0
Expires: Thu, 22 Oct 2015 11:55:23 GMT\n\n Fatal error: Uncaught Exception: DateTime::__construct(): Failed to parse time string (D, d M Y H:i:s O) at position 5 (M): Double timezone specification in /in/AbInk:7 Stack trace: #0 /in/AbInk(7): DateTime->__construct('D, d M Y H:i:s ...') #1 {main} thrown in /in/AbInk on line 7
Process exited with code 255.
Output for 5.4.0 - 5.6.28
Expires: Thu, 22 Oct 2015 11:55:23 GMT\n\n Fatal error: Uncaught exception 'Exception' with message 'DateTime::__construct(): Failed to parse time string (D, d M Y H:i:s O) at position 5 (M): Double timezone specification' in /in/AbInk:7 Stack trace: #0 /in/AbInk(7): DateTime->__construct('D, d M Y H:i:s ...') #1 {main} thrown in /in/AbInk on line 7
Process exited with code 255.