3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = DateTime::createFromFormat('?d M Y H:i:s O', 'Mon, 27 Oct 2015 10:01:13 +0000'); echo $a->format('Y-m-d H:i:s'); echo PHP_EOL; $b = new DateTime(); echo $b->format('D, d M Y H:i:s O');
Output for 8.3.0 - 8.3.4
Fatal error: Uncaught Error: Call to a member function format() on false in /in/XEthW:4 Stack trace: #0 {main} thrown in /in/XEthW on line 4
Process exited with code 255.
Output for 7.3.16 - 7.3.33, 7.4.0 - 7.4.33, 8.0.0 - 8.0.30, 8.1.0 - 8.1.27, 8.2.0 - 8.2.17
Fatal error: Uncaught Error: Call to a member function format() on bool in /in/XEthW:4 Stack trace: #0 {main} thrown in /in/XEthW on line 4
Process exited with code 255.
Output for 7.0.0 - 7.0.31, 7.1.0 - 7.1.23, 7.2.0 - 7.2.33
Fatal error: Uncaught Error: Call to a member function format() on boolean in /in/XEthW:4 Stack trace: #0 {main} thrown in /in/XEthW on line 4
Process exited with code 255.
Output for 5.6.0 - 5.6.38
Fatal error: Call to a member function format() on boolean in /in/XEthW on line 4
Process exited with code 255.
Output for 5.5.0 - 5.5.38
Fatal error: Call to a member function format() on a non-object in /in/XEthW on line 4
Process exited with code 255.

preferences:
237.62 ms | 401 KiB | 282 Q