timezone_abbreviations_list()
Introduction:
Introduction:
When working with PHP, it is essential to have a good understanding of time zones and their abbreviations. Time zones are critical for synchronizing date and time across different regions, ensuring that your applications handle temporal data correctly. This chapter explains the timezone_abbreviations_list() function and provides a reference list of common timezone abbreviations. Note: This function was deprecated in PHP 8.1 and removed in PHP 8.2. Modern PHP applications should use DateTimeZone::listAbbreviations() instead. Many abbreviations, such as CST, BST, and AST, are ambiguous and map to multiple regions worldwide.
The timezone_abbreviations_list() Function:
Deprecated in PHP 8.1, removed in PHP 8.2. For current PHP versions, use DateTimeZone::listAbbreviations() to retrieve an array of timezone abbreviations, their corresponding IANA identifiers, and UTC offsets. PHP primarily uses IANA identifiers (e.g., America/New_York, Europe/London) rather than 2-4 letter abbreviations for reliable date/time handling, as abbreviations can be ambiguous or change over time. Because of this ambiguity, production applications should always resolve to IANA identifiers using DateTimeZone.
$abbreviations = DateTimeZone::listAbbreviations();
print_r($abbreviations);To map abbreviations to their IANA identifiers and offsets, you can iterate through the returned array:
$abbreviations = DateTimeZone::listAbbreviations();
foreach ($abbreviations as $abbr => $zones) {
foreach ($zones as $zone) {
echo "{$abbr} => {$zone['timezone_id']} (UTC {$zone['offset']})\n";
}
}PHP Timezone Abbreviations:
Below is a reference list of common timezone abbreviations (standardized to uppercase to match PHP's output):
- ACDT - Australian Central Daylight Time
- ACST - Australian Central Standard Time
- ACT - Acre Time
- ADT - Atlantic Daylight Time
- AEDT - Australian Eastern Daylight Time
- AEST - Australian Eastern Standard Time
- AFT - Afghanistan Time
- AKDT - Alaska Daylight Time
- AKST - Alaska Standard Time
- AMST - Amazon Summer Time
- AMT - Amazon Time
- ART - Argentina Time
- AST - Atlantic Standard Time
- AWST - Australian Western Standard Time
- AZOST - Azores Standard Time
- AZT - Azerbaijan Time
- BDT - Brunei Time
- BNT - Brunei Darussalam Time
- BOT - Bolivia Time
- BRST - Brasilia Summer Time
- BRT - Brasilia Time
- BST - British Summer Time
- BTT - Bhutan Time
- CAT - Central Africa Time
- CCT - Cocos Islands Time
- CDT - Central Daylight Time
- CEST - Central European Summer Time
- CET - Central European Time
- CHADT - Chatham Island Daylight Time
- CHAST - Chatham Island Standard Time
- CHOT - Choibalsan Standard Time
- CHST - Chamorro Standard Time
- CHT - Chuuk Time
- CKT - Cook Island Time
- CLST - Chile Summer Time
- CLT - Chile Standard Time
- COT - Colombia Time
- CST - Central Standard Time
- CT - Central Time
- CVT - Cape Verde Time
- CWST - Central Western Standard Time
- CXT - Christmas Island Time
- DAVT - Davis Time
- DDUT - Dumont-d'Urville Time
- EASST - Easter Island Summer Time
- EAST - Easter Island Standard Time
- EAT - Eastern Africa Time
- ECT - Eastern Caribbean Time
- EDT - Eastern Daylight Time
- EEST - Eastern European Summer Time
- EET - Eastern European Time
- EGST - Eastern Greenland Summer Time
- EGT - Eastern Greenland Time
- EIT - Eastern Indonesian Time
- EST - Eastern Standard Time
- FET - Further Eastern European Time
- FJT - Fiji Time
- FKST - Falkland Islands Summer Time
- FKT - Falkland Islands Time
- FNT - Fernando de Noronha Time
- GALT - Galapagos Time
- GAMT - Gambier Islands Time
- GET - Georgia Standard Time
- GFT - French Guiana Time
- GILT - Gilbert Island Time
- GIT - Gambier Island Time
- GMT - Greenwich Mean Time
- GST - Gulf Standard Time
- GYT - Guyana Time
- HADT - Hawaii-Aleutian Daylight Time
Note: This is a partial reference list. The DateTimeZone::listAbbreviations() function returns a comprehensive array of all registered abbreviations, which can be iterated programmatically as shown above.
Practice
Which of the following are valid timezone abbreviations as per the PHP timezone abbreviations list available on W3docs?