note 54685 added to function.unixtojd

From: Date: Tue, 12 Jul 2005 21:11:13 +0000
Subject: note 54685 added to function.unixtojd
Groups: php.notes 
Request: Send a blank email to php-notes+get-91829@lists.php.net to get a copy of this message
Well, that's neither a bug, nor an interesting quirk.. The explanation is quite simple: The Integer containing a julian date (jd) only stores the date, not the time. When you convert a unix-timestamp, which stores also the time, into a jd, the time-information won't be transferred into the jd. When converting back the jd into a unix-timestamp, you'll get a timestamp for the specific day at 2 o'clock am. ( 02:00:00 ) Sample: Timestamp: 1121206013 JD: 2453565 Timestamp from JD: 1121212800 Original Timestamp "d.m.y H:i:s": 13.07.2005 00:06:53 Timstamp from JD "d.m.y H:i:s": 13.07.2005 02:00:00 greetz ---- Manual Page -- http://www.php.net/manual/en/function.unixtojd.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+54685 Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+54685&report=yes&reason=added+to+the+manual Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+54685&report=yes&reason=bad+code Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+54685&report=yes&reason=spam Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+54685&report=yes&reason=useless Delete: non-english -- http://master.php.net/manage/user-notes.php?action=delete+54685&report=yes&reason=non-english Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+54685&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+54685&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#91829) next »