#36818 [Csd->Bgs]: time() returns UTC time instead of local time
| From: | bjori@php.net | Date: | Wed, 22 Mar 2006 12:17:32 +0000 |
| Subject: | #36818 [Csd->Bgs]: time() returns UTC time instead of local time | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-94762@lists.php.net to get a copy of this message | ||
ID: 36818
Updated by: bjori@php.net
Reported By: liber at iproom dot com
-Status: Closed
+Status: Bogus
Bug Type: *General Issues
Operating System: Windows XP
PHP Version: 5.1.2
New Comment:
no bug -> bogus
Previous Comments:
------------------------------------------------------------------------
[2006-03-22 04:24:24] liber at iproom dot com
can use date_default_timezone_set() to solve this problem.
------------------------------------------------------------------------
[2006-03-22 04:05:24] liber at iproom dot com
Description:
------------
time()
On Windows XP:
it will shows UTC time.
On Linux:
it will shows local time correctly.
Reproduce code:
---------------
echo date("Y-m-d H:i:s",time());
Expected result:
----------------
return local time
Actual result:
--------------
return UTC time
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=36818&edit=1