Home » Internationalization » I18Nv2 » Bug #2361
Handle the ordinal suffix
Details
| Request #2361 | Handle the ordinal suffix |
|---|---|
| Submitted | 2004-09-20 13:18 UTC |
| From | vv at connecte dot net |
| Status | Wont fix |
| Package | I18Nv2 |
| PHP Version | 4.3.6 |
| OS | Linux Debian |
| Roadmaps | (Not assigned) |
Comments
[2004-09-20 13:18 UTC] vv at connecte dot net
Description:
------------
Hello
When you write well formated date in english you write :
the 29th of august 2004
The problem get more complicated with the first or the second :
in english : The 1st of august 2004
in french : Le 1er Août 2004
Is it possible to get the ordinal suffix for the I18Nv2_DATETIME_LONG ?
(Like the patch for : en I18Nv2_DATETIME_FULL)
Reproduce code:
---------------
include_once 'I18Nv2.php';
$oLc = &I18Nv2::createLocale(LANG);
$oLc->formatDate(strtotime(), I18Nv2_DATETIME_LONG);
Expected result:
----------------
20th of September 2004
Actual result:
--------------
20 September 2004
[2004-09-20 13:27 UTC] vv at connecte dot net
>> Like the patch for : en I18Nv2_DATETIME_FULL
> Which patch?
I18Nv2_DATETIME_FULL => '%H:%M o\'clock %Z'
The use of o'clock is usefull only in english
[2004-09-20 13:34 UTC] vv at connecte dot net
> Yes, but it's independent of the actual time, whereas 1st > and 2nd are not.
I agree with you.
It's also easy to add "of" in the date the 29th of August 2004.
But it's more professionnal to get the ordinal suffix in long date. Isn't it ?
[2004-09-20 13:46 UTC] vv at connecte dot net
No problem.
Do you have an UML model of the classes or some more documentation ?
I'will try to do it myself.
Thanks for your quickness.