From: radio_jed at hotmail dot com
Operating system: Win32 (XP Corp. Pro)
PHP version: 4.3.2
PHP Bug Type: Unknown/Other Function
Bug description: Inconsistent time zone from date()
Description:
------------
I am running PHP 4.3.2 with Apache2 (yes, I'm sorry), and I'm trying to
use date() to display my computer's time zone. I am in PST (Pacific
Standard Time, America/Los_Angeles), but date() is returning "BST" when I
use "T" in date()'s format (the other parameters in the format string
don't influence this at all.) I'm not sure what BST is.
Unchecking "automatically set clock for daylight savings time changes" in
Windows' time applet did not fix this problem, either, unlike bug #24912
suggests; not even after a reboot.
Install info:
PHP 4.3.2 ZIP binary from php.net (I did not compile my own)
Apache/Win32 2.0.47, using Apache2 SAPI module
Windows XP Corporate Professional Edition
No relevant differences in php.ini.
Reproduce code:
---------------
<?php
/* run on PHP 4.3.2, Win XP Corp. Pro
I'm not sure if this affects other OSes
I removed function's real purpose, not necessary */
file = "some/file";
printf("modified %s", date("Hi T", filemtime($file)));
?>
/* that's my original problem, this demonstrates as well:
<?php
print(date("Hi T"));
?>
*/
Expected result:
----------------
modified 1340 PST
Actual result:
--------------
modified 1340 BST
--
Edit bug report at http://bugs.php.net/?id=25261&edit=1
--
Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=25261&r=trysnapshot4
Try a CVS snapshot (php5): http://bugs.php.net/fix.php?id=25261&r=trysnapshot5
Fixed in CVS: http://bugs.php.net/fix.php?id=25261&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=25261&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=25261&r=needtrace
Try newer version: http://bugs.php.net/fix.php?id=25261&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=25261&r=support
Expected behavior: http://bugs.php.net/fix.php?id=25261&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=25261&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=25261&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=25261&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=25261&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=25261&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=25261&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=25261&r=gnused