Format Date/Time Advanced
This is an open discussion with 8 replies, filed under XSLT.
Search
There is a small typo in the documentation of this utility. It states:
%m0; Month of year, shorthand: Jan, Mar, Sep.
But this should be:
%m-; Month of year, shorthand: Jan, Mar, Sep.
i've modified this to correctly accept times in the iso format (unless i was doing it incorrectly before) as well as not output the 12-hour time of noon and midnight as "0".
I ve modified the code of buzzomatic to correctly output pm for noon. Don't know if it s the same as fawx... you can download it here
Been wondering for a while on what's the best approach, but how do you guys implement this for multilingual sites? Where strings like 'January' and 'Februari' should also be translated?
I add a test (choose
, when
...) for the current language to my date/time utility, inside the relevant templates, so it chooses which month/day names to display. I'm using the Language redirect extension.
Not sure if it's the best approach but works great for me and everything is in one place.
I just installed - and played around with - the gettext extension by Remie and it works great. Would probably be a nice add on for this. Check it out.
I'm using Frontend Localisation and created a calendar translation which is included in needed pages.
There's a typo in the docs:
%m0; Month of year, shorthand: Jan, Mar, Sep.
This should actually be:
%m-; Month of year, shorthand: Jan, Mar, Sep.
Create an account or sign in to comment.
A new XSLT utility, “Format Date/Time Advanced” is now available for download. Comments and feedback can be left here but if you discover any issues, please post it on the issue tracker.