php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #16445 mktime
Submitted: 2002-04-05 04:51 UTC Modified: 2002-04-05 15:18 UTC
From: delorme dot maxime at free dot fr Assigned:
Status: Closed Package: Documentation problem
PHP Version: 4.1.2 OS: any
Private report: No CVE-ID: None
 [2002-04-05 04:51 UTC] delorme dot maxime at free dot fr
for ($i = 0 ; $i< 365; $i++){
$date = mktime(0,0,0,1,$i,2001);
$date1 = mktime(0,0,0,1,$i-1,2001);
if (($date - $date1 ) /3600 <> 24){
echo "<br>" .date("Y m d", $date1) . " ";
echo ($date - $date1 ) /3600 ." h";}
}
It is not explicite that the mktime function take into account the change of hour some day in the year. The consequence is that (a date return by mktime )- 86400 is not always the day before.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-04-05 05:14 UTC] sander@php.net
I'll fix that...
 [2002-04-05 15:18 UTC] sander@php.net
This bug has been fixed in CVS.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Sep 18 12:01:27 2024 UTC