-
Notifications
You must be signed in to change notification settings - Fork 142
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Trigger localization based on URL? #80
Comments
hi vilav relying on the url for your persisting your language sounds kinda fragile to me have links that point to each language would you be willing to consider a session based language switcher perhaps you could extend it to read the params from the href attribute, where the full exists, instead of the data-lang attribute regards |
Do you have any example code how I can structure that? The URL will be setup in a way that the suffix of language (de/fr etc.) is always persistent in that piece of content. the URL could be a simpler trigger to toggle language content making it easy to integrate with static and cms-based sites, do you think so? |
the github editor ate my link ! |
Hi there
The plugin looks amazing. Is there a way to trigger a string's localization based on the URL of the page?
For instance, on website.com/fr, a string like "Hello" would be "Bonjour"
Similarly on website.com/es, the string could be "Hola"?
Any tips on how to accomplish this?
The text was updated successfully, but these errors were encountered: