Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

All other Modules /

Discuss all other Modules here.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

user defined forms - change date format


Go to End


3 Posts   940 Views

Avatar
spierala

Community Member, 80 Posts

13 September 2011 at 2:04am

Hallo all,
is it possible to change the dateformat of the date pickers used in user defined forms?
i would like to have german date format.

thanks in advance,
florian

Avatar
Willr

Forum Moderator, 5523 Posts

14 September 2011 at 1:06pm

Looking at the code (https://github.com/silverstripe/silverstripe-userforms/blob/master/code/editor/EditableDateField.php#L43) it uses the date format you set with i18n::set_date_format().

Avatar
spierala

Community Member, 80 Posts

14 September 2011 at 7:46pm

hey willr!
thank you for your answer.
i tried to set in config.php:
i18n::set_date_format('dd.MM.YYYY');

but nothing changes. still the datefields show me a result like this: 09/14/2011

i use ss 2.4.5
cheers,
florian