Doc #76748 [Opn->Csd]: date format timezone abbreviations and changes not well documented
| From: | git@php.net | Date: | Wed, 04 Aug 2021 14:56:06 +0000 |
| Subject: | Doc #76748 [Opn->Csd]: date format timezone abbreviations and changes not well documented | ||
| References: | 1 | Groups: | php.doc.bugs |
| Request: | Send a blank email to doc-bugs+get-19038@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=76748&edit=1
ID: 76748
Updated by: git@php.net
Reported by: georgekazdev at gmail dot com
Summary: date format timezone abbreviations and changes not
well documented
-Status: Open
+Status: Closed
Type: Documentation Problem
Package: Date/time related
Operating System: linux
PHP Version: 7.1.20
Block user comment: N
Private report: N
New Comment:
Automatic comment on behalf of cmb69
Revision: https://github.com/php/doc-en/commit/cafd6b7449774060e37f78a6a93e42e909668c15
Log: Fix #76748: date format timezone abbreviations and changes not well documented
Previous Comments:
------------------------------------------------------------------------
[2018-08-15 16:05:30] georgekazdev at gmail dot com
changed email address
------------------------------------------------------------------------
[2018-08-15 15:49:08] georgekazdev at gmail dot com
Description:
------------
From versions 7.0.17 to 7.0.18 and from 7.1.3 to 7.1.4 many timezone abbreviations were removed as
discussed here: http://mm.icann.org/pipermail/tz/2017-February/024837.html
But the changelog (http://php.net/ChangeLog-7.php) does not mention this and neither does http://www.php.net/manual/en/function.date.php
Before the change, the expected return for the test script below was:
MVT
MVT
but after the change it's
+05
+05
To save time tracing this problem, please consider updating documentation to mention the changes,
either to say that the 'T' formatter will return the date diff if there is no
abbreviation, or to mention it in the change log. It would help in knowing that it's not a bug.
A list of valid abbreviations would also be useful.
Thanks
Test script:
---------------
<?php
$date = new DateTime('Feb 13, 2009 11:31:30 PM', new
DateTimeZone('Indian/Maldives'));
echo $date->format('T').PHP_EOL;
$date = date_create('Feb 13, 2009 11:31:30 PM',
timezone_open('Indian/Maldives'));
echo date_format($date, 'T').PHP_EOL;
Expected result:
----------------
MVT
MVT
Actual result:
--------------
+05
+05
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=76748&edit=1