#30745 [Opn->Csd]: Functions date_sunset() and date_sunrise() return incorrect timestamps.
| From: | pajoye@php.net | Date: | Thu, 10 Feb 2005 14:35:54 +0000 |
| Subject: | #30745 [Opn->Csd]: Functions date_sunset() and date_sunrise() return incorrect timestamps. | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-73760@lists.php.net to get a copy of this message | ||
ID: 30745
Updated by: pajoye@php.net
Reported By: assassin at pf dot pl
-Status: Open
+Status: Closed
Bug Type: Date/time related
Operating System: Windows XP
PHP Version: 5.0.2
-Assigned To:
+Assigned To: pajoye
New Comment:
This bug has been fixed in CVS.
Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
Thank you for the report, and for helping us make PHP better.
Previous Comments:
------------------------------------------------------------------------
[2004-11-10 12:40:02] assassin at pf dot pl
Description:
------------
Functions date_sunset() and date_sunrise() return incorrect timestamps.
Reproduce code:
---------------
$sunrise = date_sunrise(time(),SUNFUNCS_RET_TIMESTAMP);
$sunset = date_sunset(time(),SUNFUNCS_RET_TIMESTAMP);
$day_length = $sunset - $sunrise;
echo($day_length); //This line shows number of minutes, not seconds.
echo date("Y m d G:i:s", $sunrise); //This line shows incorrect time.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=30745&edit=1