Req #70801 [NEW]: More concise and clearly labeled time zones
From: scott at connerly dot net
Operating system: n/a
PHP version: Irrelevant
Package: Date/time related
Bug Type: Feature/Change Request
Bug description:More concise and clearly labeled time zones
Description:
------------
Currently, DateTimeZone::listIdentifiers() returns all 417 Zones and
Links that were ever available in the tz database. Additionally, the
only names supplied by DateTimeZone::getLocation() are the actual time
zone names, not any user-friendly names.
This request to PHP is the companion request to this request to Ruby:
https://github.com/rails/rails/issues/22088
which references this array:
https://github.com/rails/rails/blob/2cecd213702fedce27840a62d07df1359d67f351/activesupport/lib/active_support/values/time_zone.rb#L31
My requests:
- Add a mechanism to get just the primary identifiers, perhaps by a new
constant similar to ALL_WITH_BC, like PRIMARY_ACTIVE. This would return
the curated list of 149 rather than all 417.
- Add a mechanism to get the user-friendly name for an identifier.
Perhaps this could happen by adding an array element in
DateTimeZone::getLocation()s' results.
--
Edit bug report at https://bugs.php.net/bug.php?id=70801&edit=1
--
Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=70801&r=trysnapshot54
Try a snapshot (PHP 5.5): https://bugs.php.net/fix.php?id=70801&r=trysnapshot55
Try a snapshot (trunk): https://bugs.php.net/fix.php?id=70801&r=trysnapshottrunk
Fixed in SVN: https://bugs.php.net/fix.php?id=70801&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=70801&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=70801&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=70801&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=70801&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=70801&r=support
Expected behavior: https://bugs.php.net/fix.php?id=70801&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=70801&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=70801&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=70801&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=70801&r=php4
Daylight Savings: https://bugs.php.net/fix.php?id=70801&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=70801&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=70801&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=70801&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=70801&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=70801&r=mysqlcfg
Thread (5 messages)
- scott at connerly dot net