Forum Moderators: coopster

Message Too Old, No Replies

inter date conversion with language support?

         

PHPycho

6:41 am on Feb 3, 2008 (gmt 0)

10+ Year Member



Hello forums!
Can anybody know a good class/functions that supports inter date conversion ie Y-m-d to m/d/y or any inter conversion with language support.
I have found a good one at
[php.net...] but it doesnt have language support.
Can anybody give suggestions/hints in modifying above function to have
language support ie if 02/01/2007 (d/m/Y) => F-D-Y in dutch the result would be : Januari-Maandag-2007.
Thanks in advance to all fo you.

phparion

2:35 pm on Feb 3, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



let's forget about language support and find a work-around :)

make an array of 12 months names in your language and 7 weekdays. Then use a switch or FUNCTION which accepts the English name and return the corresponding (your language) name...

By the way, if you have your language support site-wise your date should be converted to local language automatically, not certain on this though.