3v4l.org

run code in 300+ PHP versions simultaneously
<?php $locale = "de"; $intlTimezone = \IntlTimeZone::createDefault(); $dateTimezone = $intlTimezone->toDateTimeZone(); $calendar = new \IntlGregorianCalendar($intlTimezone, $locale); $dateFormatter = \IntlDateFormatter::create($locale, 2, -1, $intlTimezone, $calendar, "dd.MM.y"); $time = DateTimeImmutable::createFromFormat("Y-m-d", "978-12-27", $dateTimezone); var_dump($time); var_dump($time->format("d.m.Y")); var_dump($dateFormatter->format($time));
Output for git.master, git.master_jit, rfc.property-hooks
object(DateTimeImmutable)#5 (3) { ["date"]=> string(26) "0978-12-27 13:31:03.000000" ["timezone_type"]=> int(3) ["timezone"]=> string(3) "UTC" } string(10) "27.12.0978" string(9) "22.12.978"

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:
30.06 ms | 401 KiB | 8 Q