php-src icon indicating copy to clipboard operation
php-src copied to clipboard

Unknown or bad timezone (Etc/GMT+12)

Open abramov-ks opened this issue 3 years ago • 2 comments

Description

The following code:

<?php
print_r(timezone_open('Etc/GMT+12'));

Resulted in this output: PHP Warning: timezone_open(): Unknown or bad timezone (Etc/GMT+12) in Command line code on line 1

But I expected this output instead:

DateTimeZone Object
(
    [timezone_type] => 3
    [timezone] => Etc/GMT+12
)

PHP Version

PHP 8.2.1

Operating System

Ubuntu

abramov-ks avatar Jan 12 '23 13:01 abramov-ks

it was OK with php 8.2.0

abramov-ks avatar Jan 12 '23 13:01 abramov-ks

It was already reported in #10218 and will be fixed via d12ba111e03fa4e6d76a66a029f5dbe6265b1ea9

pospjan avatar Jan 12 '23 14:01 pospjan