|
Posted by ZeldorBlat on 07/10/07 19:15
On Jul 10, 1:16 pm, Brian Kendig <b...@enchanter.net> wrote:
> I'm working with dates in several formats including 'yyyy MMM dd', but
> strtotime doesn't recognize this format and returns FALSE.
Because that isn't a supported date format.
>
> Is there a direct way to convert times from this format into
> timestamps, other than my having to whip up a simple parsing routine?
Not really -- other than turning it into a format that is recognized.
>
> My headache is that I use strtotime in a lot of places in a lot of
> files, and I'd hate to have to add a wrapper everyplace I use it. I
> wish there were a way to extend strtotime's default functionality, but
> I know that would involve hacking the PHP source code.
You should have used a wrapper everywhere to begin with. Then this
change would be trivial.
[Back to original message]
|