|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2009-09-22 20:37 UTC] jani@php.net
[2009-10-05 13:56 UTC] svn@php.net
[2009-10-05 13:57 UTC] dmitry@php.net
[2009-10-09 19:06 UTC] svn@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Wed Nov 05 20:00:01 2025 UTC |
Description: ------------ When php.ini is configured with "error_log" to a specified file (not via syslog), PHP does not log date and time of records (errors, warnings, etc.) according to the "date.timezone" configured in php.ini, it's always recorded with GMT time. PHP (5.2.6) used to work correctly with this. OS and PHP have correct time zone : $ date Tue Sep 22 19:05:32 CEST 2009 ... time on OS is correctly configured : CEST = GMT+2 print date('r T'); print gmdate('r T'); ... respectivly returns : Tue, 22 Sep 2009 19:06:12 +0200 CEST Tue, 22 Sep 2009 17:06:12 +0000 GMT ... PHP correctly configured Box : FreeBSD 7.2-RELEASE (GENERIC) Apache/2.2.13 (Unix) PHP 5.2.11 Someone says (bug 45191) this bug has been fixed in CVS on May 2009, but 2 versions of the 5.2 branch had been released since this date, and the bug is still present. Reproduce code: --------------- # php.ini : ; Log errors to specified file. error_log = "/var/log/php/php-error.log" ; Defines the default timezone used by the date functions date.timezone = "Europe/Paris" # test.php : nonexistantfunction(); Expected result: ---------------- [22-Sep-2009 18:57:55] PHP Fatal error: Call to undefined function nonexistantfunction() in /usr/home/michel/public_html/plante.php on line 9 Actual result: -------------- [22-Sep-2009 16:57:55] PHP Fatal error: Call to undefined function nonexistantfunction() in /usr/home/michel/public_html/plante.php on line 9