RE: [PHP-WIN] Help with Calendar Functions!!

From: Date: Fri, 10 Nov 2000 16:48:48 +0000
Subject: RE: [PHP-WIN] Help with Calendar Functions!!
Groups: php.windows 
Request: Send a blank email to php-windows+get-3782@lists.php.net to get a copy of this message
Thanks for the insight to the Octal issue. What do I do with the -4713 number? How do I get the Julian Day from 11/9/2000 using these functions? Does it not work with windows? Thanks in advance. -----Original Message----- From: Zak Greant [mailto:zak@php.net] Sent: Friday, November 10, 2000 9:44 AM To: Joey Garcia Cc: php-windows@lists.php.net Subject: Re: [PHP-WIN] Help with Calendar Functions!! At 09:29 AM 11/10/00 -0700, Joey Garcia wrote: >I want to take a date such as 11/09/2000 and get the Julian day which would >be something like 312, any suggestions would be much appreciated!!!! > >I tried to use the Julian2JD and JD2Julian but here are the results I got: > >$temp=juliantojd(11,09,2000); >print $temp; > >I get a result of "0" with a day of "09", but I get "2451871" when >I use >just "9", I was hoping for the Julian day of the year. I divided 2451871 by >365.25 and subtracted 4713 and I got 1999, but why was this number >returned????? 09 - the leading 0 indicated that the number is octal base. Because 09 is an invalid octal number, 0 is substituted for it. >Also, I got weird results with the JD2Julian function > >$temp=jdtojulian(301); >print $temp; > >I got the result of 10/28/-4713 That's right JDs start in 4713 BC - BS is indicated with a leading -. --zak

« previous php.windows (#3782) next »