Page 1 of 1

Counting down the days....

Posted: Tue Nov 09, 2010 3:23 am
by simonmlewis
Is there a way to say how many days are left up to a certain given date: ie. Christmas.

I know of the method to get today's date.
And I know how to convert it into the PHP format.
And I know how to get it ti convert a given date into the same format.

But how do you say : Given Date - Today's Date = "so many days" ??
that 6-7 digit number.... how do you convert that into actual days?

Easy peasy???

Re: Counting down the days....

Posted: Tue Nov 09, 2010 7:01 am
by s.dot
http://us3.php.net/manual/en/datetime.diff.php - calculates differences between two dates