Hi all, I have been working on multilingual site and would like to add a language switching block to the site. However, when I assign the language switcher block to any region and press "Save blocks", a warning message "The language switcher will appear only after configuring language detection. You need to enable at least one method that alters URLs like URL or Session." is shown and the language switcher is failed to be added to the designated region.

I have configured both "User interface text language detection" and "Content language detection" under "/admin/config/regional/language/configure" to URL and used Path prefix as the Part of the URL that determines language. The site is able to have its content switched by adding / to the URL, but I still unable to add the switcher block to any region, and with the same warning message.

Any idea why I can't add the language switcher block?

Thanks all

Comments

wusel’s picture

Do you have more than one language enabled for users?

Or look at "Install a language" (https://www.drupal.org/node/21145),

then at "Enable language negotiation" (https://www.drupal.org/node/1497176)

Good luck!

Wusel

wusel’s picture

No, that is not the point!

You have to enable "URL - Determine the language from the URL (Path prefix or Domain)." properly!

Good luck!

Wusel