2

I have a multilingual website that is currently in 5 languages. We are going to be adding more - a lot more.

Views has a Filter, "Language: Current user's language" to display content based on the language the user has selected to view the content in.

Currently we are not using that filter, and the reason is URL path setting for the Views result page. Instead, because we have to have the URL translated into the language being viewed as well, we have a block configured with an English URL page, for example, and the language filter set to English.

Instead, I need to be able to configure just one view to use the Filter "Language: Current user's language" and, when that page is viewed, I need the url to display correctly in that user's language regardless of the one entry I am allowed in the Views page configuration. I also need for this to show properly in the Menu I select there as well when the page is viewed as a translation.

How can I achieve this?

4

You should enable "Translation sets" and "Path translation" modules, both part of i18n module.

Then in admin/config/regional/i18n_translation/path, you have to add the translated paths and then add a "translation set" which will map all these pages together.

Doing this, you'll be able to switch language on your view page and retrieve the corresponding alias (same view with different current language)

See also this page on drupal.org documentation.

2

You can use Internationalization Views module as well.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.