3v4l.org

run code in 300+ PHP versions simultaneously
<?php $date = '20230121'; $date_from_format = DateTime::createFromFormat('Ymd', $date, new DateTimeZone('Euroe/Berlin')); print_r([ $date_from_format->format('j'), $date_from_format->format('F'), $date_from_format->format('Y'), ]);
Output for 8.0.1 - 8.0.27, 8.1.0 - 8.1.14, 8.2.0 - 8.2.1
Fatal error: Uncaught Exception: DateTimeZone::__construct(): Unknown or bad timezone (Euroe/Berlin) in /in/jpuGK:5 Stack trace: #0 /in/jpuGK(5): DateTimeZone->__construct('Euroe/Berlin') #1 {main} thrown in /in/jpuGK on line 5
Process exited with code 255.

preferences:
18.72 ms | 406 KiB | 5 Q