Block views aren't translated in a multilanguage environment

Permalink
I set up a multilanguage site (en/de) as described by Franz here:https://www.youtube.com/watch?v=bZIqxGAS1FE...
Thx to Franz for that.
So far I had no problems to do so, everything is fine BUT...

The blocks in the frontend are still in English even if the url-slug contains .../de/...
The thing is that the default language in the dashboard under /dashboard/system/basics/multilingual is set to English (cause I'm a developer and it's better to have the site in English). If I change that to German, the block in the frontend is (naturally) changed to German, so the translation for that block (conversation) exists.

Now the question: How do I tell c5 to change the langugae according to the url slug without changing the dashboard setting? (cause that makes no sense to me)

daenu
 
hutman replied on at Permalink Reply
hutman
I haven't worked with multilingual in 5.7 but there is an option in the Dashboard -> System & Settings that is called "Translate Site Interface" this might be where you put in the translations you want to see on your site. I don't know this for sure, but it's worth checking on.
daenu replied on at Permalink Reply
daenu
Hi hutman

The "Translate Site Interface" is for translating Area Names etc. but not for translating block views. I had a chat in #concrete5 and it seems not possible without changing the dashboard language. So here's the hack I'm doing for the moment until I find another possibility:
if(strpos($_SERVER['REQUEST_URI'], 'de') !== false) {
    Config::save('concrete.locale', 'de_DE');
} else {
    Config::save('concrete.locale', 'en_US');
}

This changes the dashboard language and so the block views are translated.