Bug #54466 [Fbk->Csd]: Timezone offset for America/Caracas is wrong
| From: | jose dot zap at gmail dot com | Date: | Wed, 06 Apr 2011 14:42:21 +0000 |
| Subject: | Bug #54466 [Fbk->Csd]: Timezone offset for America/Caracas is wrong | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-159982@lists.php.net to get a copy of this message | ||
Edit report at http://bugs.php.net/bug.php?id=54466&edit=1
ID: 54466
User updated by: jose dot zap at gmail dot com
Reported by: jose dot zap at gmail dot com
Summary: Timezone offset for America/Caracas is wrong
-Status: Feedback
+Status: Closed
Type: Bug
Package: Date/time related
PHP Version: 5.3.6
Block user comment: N
Private report: N
New Comment:
Sorry for opening the ticket with so little information, and thank you
very much
for your reply. I was using a third party library fro listing all
timezones along
with their offsets and while all seemed right, this one was listed as
-5.5, I
tested the code you provided and in fact -4.5 is returned. I guess I'll
have to
fix the library instead.
Again, thanks a lot for your help and sorry for wasting your time :)
Previous Comments:
------------------------------------------------------------------------
[2011-04-06 09:18:03] aharvey@php.net
I'm rather confused by your bug: DateTimeZone::listIdentifiers() doesn't
list offsets, and the code that does appears to be correct on any recent
PHP version:
<?php
$tz = new DateTimeZone("America/Caracas");
var_dump($tz->getOffset(new DateTime()) / 3600);
?>
outputs float(-4.5), which lines up with your bug.
What version of PHP are you running, what does phpinfo() list the Olson
Timezone Database Version as, and what do you get when you run the above
code?
------------------------------------------------------------------------
[2011-04-04 17:38:48] jose dot zap at gmail dot com
Description:
------------
When using DateTimeZone::listIdentifiers() the offset for
America/Caracas is shown
as GMT -5:30, when it should be GMT -4:30
This can be validated here
http://www.timeanddate.com/library/abbreviations/timezones/sa/vet.html
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/bug.php?id=54466&edit=1