3v4l.org

run code in 300+ PHP versions simultaneously
<?php $dateTime = new DateTime(); $midnight = new DateTimeImmutable($dateTime->format('Ymd'), $dateTime->getTimezone()); var_dump($dateTime->format(DATE_ISO8601)); var_dump($dateTime->getTimezone()); var_dump($midnight->format(DATE_ISO8601)); var_dump($midnight->getTimezone());
Output for git.master, git.master_jit, rfc.property-hooks
string(24) "2014-10-26T22:42:17+0100" object(DateTimeZone)#3 (2) { ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" } string(24) "2014-10-26T00:00:00+0200" object(DateTimeZone)#3 (2) { ["timezone_type"]=> int(3) ["timezone"]=> string(16) "Europe/Amsterdam" }

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
33.63 ms | 401 KiB | 8 Q