Forums / Setup & design / date format in norwegian
risto CMS user
Monday 06 February 2006 3:29:51 am
my override of ezdate.tpl looks like this:
{section show=$attribute.content.is_valid}{$attribute.content.day}.{$attribute.content.month}.{$attribute.content.year}{/section}
Iwould like to have it display the date as:
monday 06 Feb. 2006 (but in norwegian how can I doo that?
Mads Ovesen
Tuesday 07 February 2006 5:12:03 am
Have you set
[RegionalSettings] ContentObjectLocale=nor-NO
in your site.ini.append.php file??
/mads
/m
Tuesday 07 February 2006 6:09:06 am
ok this I have and it works fine on datetime.
but can it work on a date field?
why dosent this work?
{$node.object.data_map.date|l10n(date)}
Tuesday 07 February 2006 11:48:15 am
That won't give the correct output. You will need a Unix timestamp as input to l10n to give you the correct output (i.e. monday 06 Feb. 2006). Fx look at the attributes for the ezdate datatype:
http://ez.no/doc/ez_publish/technical_manual/3_6/reference/objects/ezdate
The timestamp attribute contains the the Unix timestamp that you can use.
/Mads