RE: [PHP] Calculating the difference between two dates
| From: | Don Read | Date: | Mon, 24 Mar 2003 02:24:33 +0000 |
| Subject: | RE: [PHP] Calculating the difference between two dates | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-140790@lists.php.net to get a copy of this message | ||
On 24-Mar-1998 Beauford.2002 wrote:
> Does any one know how to calculate the difference between two dates. I
> need
> to find out the age of a user to make sure they are over the age of 13. I
> have searched for hours on this and found nothing that will help.
>
Start here:
echo date('Y-m-d', strtotime('13 years ago'));
Sorry, it doesn't check the birth certificate ;)
Regards,
--
Don Read dread@texas.net
-- It's always darkest before the dawn. So if you are going to
steal the neighbor's newspaper, that's the time to do it.