From:             
Operating system: Ubuntu Linux 10.04
PHP version:      5.3.3
Package:          *Calendar problems
Bug Type:         Bug
Bug description:Europe/London is in two timezones

Description:
------------
I was about to create a timezone selector widget with map and select box
with the timezone IDs, but when I asked for the full timezone list with
DateTimeZone::listAbbreviations() I saw that Europe/London is in two
different timezones according to the Greenwich Mean Time:



- "bdst": DST is TRUE, offset is GMT+2 hours (== DST:false and GMT+1)

- "bst":  offset is GMT+1 hour and DST doesn't matter, both TRUE (== GMT+0)
and FALSE (== GMT+1) can be found

- "gmt":  DST is FALSE, offset is GMT+0. It is GMT of course :)



How can this be possible?

Test script:
---------------
<?php



$dtz = DateTimeZone::listAbbreviations();

die('<pre>'.print_r($dtz, true).'</pre>');



// and search for 'Europe/London' or see description below







Expected result:
----------------
GMT+1 in Summer and GMT+0 otherwise. Something like:



["bst"] => array(25) {

    [0] => array(3) {

      ["dst"] => bool(true)

      ["offset"] => int(3600)

      ["timezone_id"] => string(13) "Europe/London"

    }

    ...

}

...

["gmt"] => array(30) {

    ...

    [26] => array(3) {

      ["dst"] => bool(false)

      ["offset"] => int(0)

      ["timezone_id"] => string(13) "Europe/London"

    }

    ...

}



Actual result:
--------------
...

["bdst"] => array(8) {

   [0] => array(3) {

      ["dst"] => bool(true)

      ["offset"] => int(7200)

      ["timezone_id"] => string(13) "Europe/London"

   }

   ...

}

...

["bst"] => array(25) {

    [0] => array(3) {

      ["dst"] => bool(false)

      ["offset"] => int(3600)

      ["timezone_id"] => string(13) "Europe/London"

    }

    [1] => array(3) {

      ["dst"] => bool(true)

      ["offset"] => int(3600)

      ["timezone_id"] => string(13) "Europe/London"

    }

    ...

}

...

["gmt"] => array(30) {

    ...

    [26] => array(3) {

      ["dst"] => bool(false)

      ["offset"] => int(0)

      ["timezone_id"] => string(13) "Europe/London"

    }

    ...

}

...

-- 
Edit bug report at http://bugs.php.net/bug.php?id=53078&edit=1
-- 
Try a snapshot (PHP 5.2):            
http://bugs.php.net/fix.php?id=53078&r=trysnapshot52
Try a snapshot (PHP 5.3):            
http://bugs.php.net/fix.php?id=53078&r=trysnapshot53
Try a snapshot (trunk):              
http://bugs.php.net/fix.php?id=53078&r=trysnapshottrunk
Fixed in SVN:                        
http://bugs.php.net/fix.php?id=53078&r=fixed
Fixed in SVN and need be documented: 
http://bugs.php.net/fix.php?id=53078&r=needdocs
Fixed in release:                    
http://bugs.php.net/fix.php?id=53078&r=alreadyfixed
Need backtrace:                      
http://bugs.php.net/fix.php?id=53078&r=needtrace
Need Reproduce Script:               
http://bugs.php.net/fix.php?id=53078&r=needscript
Try newer version:                   
http://bugs.php.net/fix.php?id=53078&r=oldversion
Not developer issue:                 
http://bugs.php.net/fix.php?id=53078&r=support
Expected behavior:                   
http://bugs.php.net/fix.php?id=53078&r=notwrong
Not enough info:                     
http://bugs.php.net/fix.php?id=53078&r=notenoughinfo
Submitted twice:                     
http://bugs.php.net/fix.php?id=53078&r=submittedtwice
register_globals:                    
http://bugs.php.net/fix.php?id=53078&r=globals
PHP 4 support discontinued:          http://bugs.php.net/fix.php?id=53078&r=php4
Daylight Savings:                    http://bugs.php.net/fix.php?id=53078&r=dst
IIS Stability:                       
http://bugs.php.net/fix.php?id=53078&r=isapi
Install GNU Sed:                     
http://bugs.php.net/fix.php?id=53078&r=gnused
Floating point limitations:          
http://bugs.php.net/fix.php?id=53078&r=float
No Zend Extensions:                  
http://bugs.php.net/fix.php?id=53078&r=nozend
MySQL Configuration Error:           
http://bugs.php.net/fix.php?id=53078&r=mysqlcfg

Reply via email to