note 102713 deleted from function.date by tularis
| From: | tularis@php.net | Date: | Mon, 05 Sep 2011 13:04:12 +0000 |
| Subject: | note 102713 deleted from function.date by tularis | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-182953@lists.php.net to get a copy of this message | ||
Note Submitter: bsntech
----
Found it useful to do some quick calculations on a date by doing something like this.
$var = date('F d, Y', strtotime("-1 month -4 days"));
This quickly returns something like this:
February 28, 2011
But, it will return the date that was one month and four days from the current date. Easy to get
calculations based on that especially in cases where there are not 31 days in a month.
Brian S.
BsnTech Networks