Since the latest updates, we’ve noticed that our default site language has changed from German to English. The global site setting “default locale” isn’t available any more.
How can change the site language again?
Thanks,
M
Missing setting: default locale
After the latest updates, terraboss noticed their site’s default language changed from German to English, and the “default locale” setting was no longer available. Simon suggested checking the app.yml file for DISCOURSE_DEFAULT_LOCALE settings. Commenting out this line restored the “default locale” setting, but the site still defaulted to English for non-logged in users.
Simon explained that the locale for non-logged in users is now set by HTTP accept-language headers for sites that allow users to select their locale. This change likely caused the issue, as terraboss’s default system language is English.
@simon is this related to your recent change somehow?
Not in a way that I’m seeing, but I’ll keep looking. @terraboss are there any errors in the javascript console?
Did you set DISCOURSE_DEFAULT_LOCALE in app.yml?
If I’m not mistaken the default locale can’t be changed when it’s set via environment variable.
That’s the only way I’ve been able to reproduce this.
Originally, I’ve set DISCOURSE_DEFAULT_LOCALE: de;
Commenting it out, brought me the setting back again. Unfortunately, telling Discourse that I wanna use German as default language didn’t show any effect. That means, the logged in user has it’s correct language but not someone who isn’t logged in. These people still have to deal with English.
Any clue why?
What’s the url for your site?
I think it’s because the locale for non-logged in users is now being set by the HTTP accept-language headers for sites that allow users to select their locale.
haha, thanks, good to know ![]()
My default system language is English for a couple of reasons ![]()