3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $date = new DateTime('front of 5am'); echo $date->format('h:m:s d-m-Y');
Output for 7.1.0alpha1 - 7.1.0
04:05:00 08-05-2013
Output for 7.0.6
04:05:00 03-05-2016
Output for 7.0.5
04:04:00 02-04-2016
Output for 7.0.4
04:03:00 09-03-2016
Output for 7.0.3
04:03:00 17-03-2016
Output for 7.0.2
04:03:00 21-03-2016
Output for 7.0.1
04:03:00 23-03-2016
Output for 7.0.0
04:03:00 26-03-2016
Output for hhvm-3.12.0
04:03:00 11-03-2016
Output for hhvm-3.10.0
04:03:00 29-03-2016
Output for 5.6.21
04:05:00 01-05-2016
Output for 5.6.20
04:04:00 09-04-2016
Output for 5.6.19
04:03:00 06-03-2016
Output for 5.6.18
04:03:00 14-03-2016
Output for 5.6.17
04:03:00 19-03-2016
Output for 5.6.16
04:03:00 27-03-2016
Output for 5.6.15
04:03:00 28-03-2016
Output for 5.6.14
04:04:00 01-04-2016
Output for 5.6.13
04:04:00 14-04-2016
Output for 5.6.12
04:04:00 19-04-2016
Output for 5.6.11
04:04:00 22-04-2016
Output for 5.6.10
04:04:00 24-04-2016
Output for 5.6.9
04:04:00 27-04-2016
Output for 5.6.8
04:04:00 29-04-2016
Output for 5.6.7
04:05:00 24-05-2016
Output for 5.5.35
04:05:00 21-05-2016
Output for 5.5.34
04:04:00 10-04-2016
Output for 5.5.33
04:03:00 08-03-2016
Output for 5.5.32
04:03:00 15-03-2016
Output for 5.5.31
04:03:00 20-03-2016
Output for 5.5.30
04:03:00 31-03-2016
Output for 5.5.29
04:04:00 16-04-2016
Output for 5.5.28
04:04:00 20-04-2016
Output for 5.5.27
04:04:00 21-04-2016
Output for 5.5.26
04:04:00 25-04-2016
Output for 5.5.25
04:04:00 28-04-2016
Output for 5.5.24
04:04:00 30-04-2016
Output for 5.3.0 - 5.4.45
04:02:00 19-02-2016
Output for 5.2.0 - 5.2.17
Fatal error: Uncaught exception 'Exception' with message 'DateTime::__construct(): Failed to parse time string (front of 5am) at position 0 (f): The timezone could not be found in the database' in /in/t8GEA:2 Stack trace: #0 /in/t8GEA(2): DateTime->__construct('front of 5am') #1 {main} thrown in /in/t8GEA on line 2
Process exited with code 255.
Output for 5.0.0 - 5.1.6
Fatal error: Class 'DateTime' not found in /in/t8GEA on line 2
Process exited with code 255.
Output for 4.3.2 - 4.4.9
Fatal error: Cannot instantiate non-existent class: datetime in /in/t8GEA on line 2
Process exited with code 255.
Output for 4.3.0 - 4.3.1
Fatal error: Cannot instantiate non-existent class: datetime in /in/t8GEA on line 2