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.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

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

Blog refuses to use locale settings


Go to End


1078 Views

Avatar
Fairfax71

Community Member, 20 Posts

29 November 2012 at 9:17pm

Hi all,

I'm using the latest install of the blog module and Silverstripe 3.0.3. I've been trying to get the blog to use the de_DE locale, but with no luck at all – it insists on using the default en_US formatting for date and time.

I checked the server and the German locale must be set to de_DE.UTF8. I've tried this in mysite/_config.php as well as in blog/_config.php:

// Set the site locale
setlocale(LC_ALL, 'de_DE@euro', 'de_DE', 'de', 'ge', 'de_DE.UTF8');
i18n::set_locale('de_DE');
i18n::include_locale_file('blog', 'de_DE');

and also tried creating a lang file called de_DE.UTF8.php and setting

i18n::set_locale('de_DE.UTF8');
i18n::include_locale_file('blog', 'de_DE.UTF8');

but to no avail.

Help?