In this article, you will learn more about getting the information out of the timezone of a date. The timezone_identifiers_list() method returns an array that contains the identifiers of the timezone.
What is the syntax of the TIMEZONE_IDENTIFIERS_LIST() function in PHP?
timezone_identifiers_list(what, country)
Parameter | Description |
---|---|
what | The DateTime object 1 = AFRICA 2 = AMERICA 4 = ANTARCTICA 8 = ARCTIC 16 = ASIA 32 = ATLANTIC 64 = AUSTRALIA 128 = EUROPE 256 = INDIAN 512 = PACIFIC 1024 = UTC 2047 = ALL 4095 = ALL_WITH_BC 4096 = PER_COUNTRY |
country | Specify the country code |
Examples of the TIMEZONE_IDENTIFIERS_LIST() function
Example 1. In this example, timezone_identifiers_list() method to get the timezone identifiers information.
<?php
print_r(timezone_identifiers_list(1));
?>