#47574 [NEW]: date() function works incorrect :-(
| From: | privatevideo at list dot ru | Date: | Thu, 05 Mar 2009 16:57:40 +0000 |
| Subject: | #47574 [NEW]: date() function works incorrect :-( | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-134435@lists.php.net to get a copy of this message | ||
From: privatevideo at list dot ru
Operating system: Windows
PHP version: 5.2.9
PHP Bug Type: Date/time related
Bug description: date() function works incorrect :-(
Description:
------------
date() function works incorrect :-(
Reproduce code:
---------------
# check line 179-180, it should add a minute every step
for ($i=0,$d=1224964800;$d<=1225051200;$d+=60,++$i)
echo "<br>$i -> ".date('Y-m-d H:i:s',$d);
Expected result:
----------------
179 -> 2008-10-26 02:59:00
180 -> 2008-10-26 03:00:00
181 -> 2008-10-26 03:01:00
182 -> 2008-10-26 03:02:00
Actual result:
--------------
179 -> 2008-10-26 02:59:00
180 -> 2008-10-26 02:00:00
181 -> 2008-10-26 02:01:00
182 -> 2008-10-26 02:02:00
--
Edit bug report at http://bugs.php.net/?id=47574&edit=1
--
Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=47574&r=trysnapshot52
Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=47574&r=trysnapshot53
Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=47574&r=trysnapshot60
Fixed in CVS: http://bugs.php.net/fix.php?id=47574&r=fixedcvs
Fixed in CVS and need be documented: http://bugs.php.net/fix.php?id=47574&r=needdocs
Fixed in release: http://bugs.php.net/fix.php?id=47574&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=47574&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=47574&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=47574&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=47574&r=support
Expected behavior: http://bugs.php.net/fix.php?id=47574&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=47574&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=47574&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=47574&r=globals
PHP 4 support discontinued: http://bugs.php.net/fix.php?id=47574&r=php4
Daylight Savings: http://bugs.php.net/fix.php?id=47574&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=47574&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=47574&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=47574&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=47574&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=47574&r=mysqlcfg