# Switch language via URL?

**URL:** <https://meta.discourse.org/t/switch-language-via-url/28937>\
**Category:** Support\
**Created:** [18 Maggio 2015, 6:45am UTC](https://meta.discourse.org/t/switch-language-via-url/28937 "2015-05-18T06:45:51Z")\
**Posts on this page:** 1\
**Showing post:** 9

<div class="post-metadata">

**Author:** ![simon](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/simon/32/339122_2.png) [@simon](https://meta.discourse.org/u/simon)\
**Post date:** [8 Febbraio 2016, 3:04am UTC](https://meta.discourse.org/t/switch-language-via-url/28937/9 "2016-02-08T03:04:37Z")

</div>

If you put both the original and the translation in the same topic, maybe it would be possible to show/hide content based on the user’s locale. Something like this: [GitHub - wooorm/franc: Natural language detection · GitHub](https://github.com/wooorm/franc) could be used for language detection within the topic. Sections that are not in the user’s target language could be initially collapsed and then expanded for users who wanted to see the content in both languages.

edit:

Since you know the languages you are dealing with ahead of time you could just wrap the text for each language in a div so that Ukrainian sections would have `<div class="uk">` and English sections `<div class="en">` and then show/hide those sections based on the user’s locale.

---

_[View the full topic](https://meta.discourse.org/t/switch-language-via-url/28937)._
