Hello,
as I found out, Translatable::set_current_locale("de_DE") hast absolutely no effect.
In mysite/_config.php I set:
Object::add_extension('Page', 'Translatable');
Translatable::enable();
Translatable::set_default_locale("de_DE");
Translatable::set_current_locale("de_DE");
I even tried to set default_locale to "de_DE" in Translateable.php even without effect. Each time I read locale with Translatable::get_current_locale() in my Page_Controller::Init() "en_US" is returned. However my database has correct values set, i.e. all default sites are set to default locale "de_DE".
There is no sense to set Translatable::set_default_locale("de_DE") if it is always ignored.
What I want to do is to select locales by following conditions:
1. Locale should be set to "de_DE" by default
2. Locale should be set to current logged on member locale (if available)
3. Locale should be determined by browser settings ($_SERVER['HTTP_ACCEPT_LANGUAGE'])
As I read, Page_Controller::Init() is the best place to do this, is this right?
By the way using ?locale=de_DE even had no effect, don't know why.
I'm using SS 2.3.4.
Yours,
bkausbk