Re: function.date.php
| From: | Jochem Maas | Date: | Wed, 25 Feb 2004 21:05:54 +0000 |
| Subject: | Re: function.date.php | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-178886@lists.php.net to get a copy of this message | ||
John Taylor-Johnston wrote:
Is there a way to reverse engineer http://www.php.net/manual/en/function.date.php ? I want to feed in 2003-02-28 and extract February 28, 2003. I can substr it out ... $eventid = "2003-02-28"; $year = substr($eventid, 0,4); $month = substr($eventid, 5,7); $year = substr($eventid, 8,10); But there must be a function that would do it? Everything else exists :)yes there is: take a look at the strtotime() and strftime() functions in the manual.