Re: Date math
| From: | Casey | Date: | Mon, 24 Mar 2008 04:56:58 +0000 |
| Subject: | Re: Date math | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-272026@lists.php.net to get a copy of this message | ||
On Sun, Mar 23, 2008 at 9:17 PM, Ron Piggott <ron.php@actsministries.org> wrote:
> I have this math equation this list helped me generate a few weeks ago.
> The purpose is to calculate how many days have passed between 2 dates.
>
<snip>
>
> $date1 = strtotime($date1); (March 21st 2008)
> $date2 = strtotime($date2); (December 18th 2007)
>
> echo $date1 => 1206072000
> echo $date2 => 1197954000
Seems to be a time zone issue.1206057600 is the actual timestamp for
March 21st, 2008 GMT. I don't know what time zone 1206072000 is is.
--
-Casey