3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function GetFormattedMicroTime($timestamp = false) { return DateTime::createFromFormat('u','53629')->format('Y-m-d\TH:i:s.u'); } $test = GetFormattedMicroTime(); print_r($test);
Output for 5.6.28, 7.0.14 - 7.1.0
2014-06-23T17:59:04.536290
Output for 7.0.6
2016-05-03T18:42:27.536290
Output for 7.0.5
2016-04-03T07:07:11.536290
Output for 7.0.4
2016-03-10T18:54:42.536290
Output for 7.0.3
2016-03-18T20:06:56.536290
Output for 7.0.2
2016-03-23T02:13:33.536290
Output for 7.0.1
2016-03-24T05:49:50.536290
Output for 7.0.0
2016-03-27T07:45:46.536290
Output for 5.6.21
2016-05-02T13:51:22.536290
Output for 5.6.20
2016-04-10T06:06:31.536290
Output for 5.6.19
2016-03-08T03:06:48.536290
Output for 5.6.18
2016-03-15T11:51:07.536290
Output for 5.6.17
2016-03-19T23:29:30.536290
Output for 5.6.16
2016-03-28T08:32:53.536290
Output for 5.6.15
2016-03-29T09:23:47.536290
Output for 5.6.14
2016-04-02T11:14:07.536290
Output for 5.6.13
2016-04-15T15:39:47.536290
Output for 5.6.12
2016-04-20T06:08:59.536290
Output for 5.6.11
2016-04-24T12:32:07.536290
Output for 5.6.10
2016-04-25T14:34:19.536290
Output for 5.6.9
2016-04-27T19:44:10.536290
Output for 5.6.8
2016-04-30T04:36:07.536290
Output for 5.5.35
2016-05-22T21:25:55.536290
Output for 5.5.34
2016-04-11T08:18:08.536290
Output for 5.5.33
2016-03-09T05:51:33.536290
Output for 5.5.32
2016-03-17T15:45:54.536290
Output for 5.5.31
2016-03-21T02:32:06.536290
Output for 5.5.30
2016-04-01T11:17:25.536290
Output for 5.5.29
2016-04-17T06:02:36.536290
Output for 5.5.28
2016-04-21T09:23:12.536290
Output for 5.5.27
2016-04-22T11:09:05.536290
Output for 5.5.26
2016-04-26T17:17:21.536290
Output for 5.5.25
2016-04-29T00:13:15.536290
Output for 5.5.24
2016-05-24T06:42:05.536290
Output for 5.4.45
2015-11-12T07:07:57.536290
Output for 5.4.44
2015-11-12T07:07:58.536290
Output for 5.4.43
2015-11-12T07:07:59.536290
Output for 5.4.42
2015-11-12T07:08:00.536290
Output for 5.4.41
2015-11-12T07:08:01.536290
Output for 5.4.39 - 5.4.40
2015-11-12T07:08:02.536290
Output for 5.4.36 - 5.4.38
2015-11-12T07:08:03.536290
Output for 5.4.34 - 5.4.35
2015-11-12T07:08:04.536290
Output for 5.3.29, 5.4.31 - 5.4.32
2015-11-12T07:08:05.536290
Output for 5.4.27 - 5.4.30
2015-11-12T07:08:06.536290
Output for 5.4.23 - 5.4.26
2015-11-12T07:08:07.536290
Output for 5.3.28, 5.4.20 - 5.4.22
2015-11-12T07:08:08.536290
Output for 5.3.27, 5.4.18 - 5.4.19
2015-11-12T07:08:09.536290
Output for 5.3.25 - 5.3.26, 5.4.15 - 5.4.17
2015-11-12T07:08:10.536290
Output for 5.3.22 - 5.3.24, 5.4.12 - 5.4.14
2015-11-12T07:08:11.536290
Output for 5.3.19 - 5.3.21, 5.4.9 - 5.4.11
2015-11-12T07:08:12.536290
Output for 5.3.15 - 5.3.18, 5.4.6 - 5.4.8
2015-11-12T07:08:13.536290
Output for 5.3.12 - 5.3.14, 5.4.3 - 5.4.5
2015-11-12T07:08:14.536290
Output for 5.3.10 - 5.3.11, 5.4.0 - 5.4.2
2015-11-12T07:08:15.536290
Output for 5.3.5 - 5.3.9
2015-11-12T07:08:16.536290
Output for 5.3.3 - 5.3.4
2015-11-12T07:08:17.536290
Output for 5.3.1 - 5.3.2
Fatal error: Call to a member function format() on a non-object in /in/4TW9m on line 3
Process exited with code 255.
Output for 5.3.0
2015-11-12T07:08:18.-2147483648
Output for 5.2.10 - 5.2.17
Fatal error: Call to undefined method DateTime::createFromFormat() in /in/4TW9m on line 3
Process exited with code 255.
Output for 5.2.0 - 5.2.9
Fatal error: Call to undefined method DateTime::createfromformat() in /in/4TW9m on line 3
Process exited with code 255.
Output for 5.0.0 - 5.1.6
Fatal error: Class 'DateTime' not found in /in/4TW9m on line 3
Process exited with code 255.
Output for 4.4.2 - 4.4.9
Parse error: syntax error, unexpected T_OBJECT_OPERATOR in /in/4TW9m on line 3
Process exited with code 255.
Output for 4.3.0 - 4.3.1, 4.3.5 - 4.4.1
Parse error: parse error, unexpected T_OBJECT_OPERATOR in /in/4TW9m on line 3
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error in /in/4TW9m on line 3
Process exited with code 255.