RE: [PHP] Subtracting dates w/o database interaction (MySQL)

2005-09-23 Thread Chris W. Parker
Philip Thompson mailto:[EMAIL PROTECTED] on Friday, September 23, 2005 9:12 AM said: I'm needing to find the number of days between two dates without using an database functions (DATE_SUB, etc)... only PHP. Is there an easy way to accomplish this? I have searched the PHP site, but have

Re: [PHP] Subtracting dates w/o database interaction (MySQL)

2005-09-23 Thread Gustav Wiberg
- Original Message - From: Philip Thompson [EMAIL PROTECTED] To: php-general@lists.php.net Sent: Friday, September 23, 2005 6:11 PM Subject: [PHP] Subtracting dates w/o database interaction (MySQL) Hey all. I'm needing to find the number of days between two dates without using an

Re: [PHP] Subtracting dates w/o database interaction (MySQL)

2005-09-23 Thread Philip Thompson
On Sep 23, 2005, at 11:16 AM, Chris W. Parker wrote: Philip Thompson mailto:[EMAIL PROTECTED] on Friday, September 23, 2005 9:12 AM said: I'm needing to find the number of days between two dates without using an database functions (DATE_SUB, etc)... only PHP. Is there an easy way to

Re: [PHP] Subtracting dates w/o database interaction (MySQL)

2005-09-23 Thread Stephen Leaf
$date = mysql date field 2005-09-23 for example $difference =ceil((strtotime($date) - time()) / 86400); strtotime is far nicer than mktime when you already have a date field ready. On Friday 23 September 2005 03:10 pm, Philip Thompson wrote: On Sep 23, 2005, at 11:16 AM, Chris W. Parker wrote: