3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $a = new datetime; print_r($a); echo $a->date, "\n"; $a->modify("+10 days"); echo $a->date, "\n";
based on kYUkf
Output for 7.2.0
DateTime Object ( [date] => 2015-12-23 09:54:33.003529 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:33.003529 2015-12-23 09:54:33.003529
Output for 7.1.10
DateTime Object ( [date] => 2015-12-23 09:54:33.002676 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:33.002676 2015-12-23 09:54:33.002676
Output for 7.1.7
DateTime Object ( [date] => 2015-12-23 09:54:33.003946 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:33.003946 2015-12-23 09:54:33.003946
Output for 7.1.6
DateTime Object ( [date] => 2015-12-23 09:54:33.013298 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:33.013298 2015-12-23 09:54:33.013298
Output for 7.1.5
DateTime Object ( [date] => 2015-12-23 09:54:33.005581 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:33.005581 2015-12-23 09:54:33.005581
Output for 7.1.0
DateTime Object ( [date] => 2015-12-23 09:54:33.004028 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:33.004028 2015-12-23 09:54:33.004028
Output for 5.6.28, 7.0.20
DateTime Object ( [date] => 2015-12-23 09:54:33.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:33.000000 2015-12-23 09:54:33.000000
Output for 7.0.6
DateTime Object ( [date] => 2016-05-21 12:55:48.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-05-21 12:55:48.000000 2016-05-21 12:55:48.000000
Output for 7.0.5
DateTime Object ( [date] => 2016-04-03 09:01:26.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-04-03 09:01:26.000000 2016-04-03 09:01:26.000000
Output for 7.0.4
DateTime Object ( [date] => 2016-03-10 21:06:34.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-03-10 21:06:34.000000 2016-03-10 21:06:34.000000
Output for 7.0.3
DateTime Object ( [date] => 2016-03-18 22:27:13.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-03-18 22:27:13.000000 2016-03-18 22:27:13.000000
Output for 7.0.2
DateTime Object ( [date] => 2016-03-23 04:41:07.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-03-23 04:41:07.000000 2016-03-23 04:41:07.000000
Output for 7.0.1
DateTime Object ( [date] => 2016-03-24 07:50:58.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-03-24 07:50:58.000000 2016-03-24 07:50:58.000000
Output for 7.0.0
DateTime Object ( [date] => 2016-03-27 09:44:36.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-03-27 09:44:36.000000 2016-03-27 09:44:36.000000
Output for 5.6.21
DateTime Object ( [date] => 2016-05-02 15:53:28.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-05-02 15:53:28.000000 2016-05-02 15:53:28.000000
Output for 5.6.20
DateTime Object ( [date] => 2016-04-10 08:03:13.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-04-10 08:03:13.000000 2016-04-10 08:03:13.000000
Output for 5.6.19
DateTime Object ( [date] => 2016-03-08 05:13:48.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-03-08 05:13:48.000000 2016-03-08 05:13:48.000000
Output for 5.6.18
DateTime Object ( [date] => 2016-03-15 14:08:21.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-03-15 14:08:21.000000 2016-03-15 14:08:21.000000
Output for 5.6.17
DateTime Object ( [date] => 2016-03-20 01:41:23.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-03-20 01:41:23.000000 2016-03-20 01:41:23.000000
Output for 5.6.16
DateTime Object ( [date] => 2016-03-28 10:34:06.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-03-28 10:34:06.000000 2016-03-28 10:34:06.000000
Output for 5.6.15
DateTime Object ( [date] => 2016-03-29 11:23:07.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-03-29 11:23:07.000000 2016-03-29 11:23:07.000000
Output for 5.6.14
DateTime Object ( [date] => 2016-04-14 17:04:54.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-04-14 17:04:54.000000 2016-04-14 17:04:54.000000
Output for 5.6.13
DateTime Object ( [date] => 2016-04-15 17:44:33.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-04-15 17:44:33.000000 2016-04-15 17:44:33.000000
Output for 5.6.12
DateTime Object ( [date] => 2016-04-20 08:13:20.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-04-20 08:13:20.000000 2016-04-20 08:13:20.000000
Output for 5.6.11
DateTime Object ( [date] => 2016-04-24 14:38:44.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-04-24 14:38:44.000000 2016-04-24 14:38:44.000000
Output for 5.6.10
DateTime Object ( [date] => 2016-04-25 16:44:05.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-04-25 16:44:05.000000 2016-04-25 16:44:05.000000
Output for 5.6.9
DateTime Object ( [date] => 2016-04-27 21:52:21.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-04-27 21:52:21.000000 2016-04-27 21:52:21.000000
Output for 5.6.8
DateTime Object ( [date] => 2016-04-30 06:40:30.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-04-30 06:40:30.000000 2016-04-30 06:40:30.000000
Output for 5.5.35
DateTime Object ( [date] => 2016-05-23 01:23:26.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-05-23 01:23:26.000000 2016-05-23 01:23:26.000000
Output for 5.5.34
DateTime Object ( [date] => 2016-04-11 10:16:38.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-04-11 10:16:38.000000 2016-04-11 10:16:38.000000
Output for 5.5.33
DateTime Object ( [date] => 2016-03-09 08:12:43.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-03-09 08:12:43.000000 2016-03-09 08:12:43.000000
Output for 5.5.32
DateTime Object ( [date] => 2016-03-17 18:04:02.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-03-17 18:04:02.000000 2016-03-17 18:04:02.000000
Output for 5.5.31
DateTime Object ( [date] => 2016-03-21 04:49:29.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-03-21 04:49:29.000000 2016-03-21 04:49:29.000000
Output for 5.5.30
DateTime Object ( [date] => 2016-04-01 13:15:55.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-04-01 13:15:55.000000 2016-04-01 13:15:55.000000
Output for 5.5.29
DateTime Object ( [date] => 2016-04-17 08:02:12.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-04-17 08:02:12.000000 2016-04-17 08:02:12.000000
Output for 5.5.28
DateTime Object ( [date] => 2016-04-21 11:31:23.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-04-21 11:31:23.000000 2016-04-21 11:31:23.000000
Output for 5.5.27
DateTime Object ( [date] => 2016-04-22 13:10:52.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-04-22 13:10:52.000000 2016-04-22 13:10:52.000000
Output for 5.5.26
DateTime Object ( [date] => 2016-04-26 19:23:07.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-04-26 19:23:07.000000 2016-04-26 19:23:07.000000
Output for 5.5.25
DateTime Object ( [date] => 2016-04-29 02:48:36.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-04-29 02:48:36.000000 2016-04-29 02:48:36.000000
Output for 5.5.24
DateTime Object ( [date] => 2016-05-24 09:14:24.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2016-05-24 09:14:24.000000 2016-05-24 09:14:24.000000
Output for 5.4.45
DateTime Object ( [date] => 2015-12-23 09:54:36.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:36.000000 2015-12-23 09:54:36.000000
Output for 5.4.44
DateTime Object ( [date] => 2015-12-23 09:54:37.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:37.000000 2015-12-23 09:54:37.000000
Output for 5.4.43
DateTime Object ( [date] => 2015-12-23 09:54:38.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:38.000000 2015-12-23 09:54:38.000000
Output for 5.4.41 - 5.4.42
DateTime Object ( [date] => 2015-12-23 09:54:39.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:39.000000 2015-12-23 09:54:39.000000
Output for 5.4.38 - 5.4.40
DateTime Object ( [date] => 2015-12-23 09:54:40.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:40.000000 2015-12-23 09:54:40.000000
Output for 5.4.35 - 5.4.37
DateTime Object ( [date] => 2015-12-23 09:54:41.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:41.000000 2015-12-23 09:54:41.000000
Output for 5.4.32 - 5.4.34
DateTime Object ( [date] => 2015-12-23 09:54:42.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:42.000000 2015-12-23 09:54:42.000000
Output for 5.4.30 - 5.4.31
DateTime Object ( [date] => 2015-12-23 09:54:43.000000 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:43.000000 2015-12-23 09:54:43.000000
Output for 5.3.29, 5.4.29
DateTime Object ( [date] => 2015-12-23 09:54:43 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:43 2015-12-23 09:54:43
Output for 5.4.25 - 5.4.28
DateTime Object ( [date] => 2015-12-23 09:54:44 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:44 2015-12-23 09:54:44
Output for 5.3.28, 5.4.21 - 5.4.24
DateTime Object ( [date] => 2015-12-23 09:54:45 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:45 2015-12-23 09:54:45
Output for 5.3.27, 5.4.18 - 5.4.20
DateTime Object ( [date] => 2015-12-23 09:54:46 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:46 2015-12-23 09:54:46
Output for 5.3.25 - 5.3.26, 5.4.14 - 5.4.17
DateTime Object ( [date] => 2015-12-23 09:54:47 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:47 2015-12-23 09:54:47
Output for 5.3.21 - 5.3.24, 5.4.11 - 5.4.13
DateTime Object ( [date] => 2015-12-23 09:54:48 [timezone_type] => 3 [timezone] => Europe/Amsterdam ) 2015-12-23 09:54:48 2015-12-23 09:54:48