Closed irumiha closed 11 years ago
It was possible, in the last version :/ Of course, this has to be possible. In this version, it is currently only possible to set the config once... I'll push some code tomorrow ;)
Now you can change options at runtime. Simply require $i18next
and then change any option you want:
$i18next.options.lng = 'dev';
$i18next.options.useCookie = true;
Great! Much easier to use than my quick solution. Thanks!
No problem.
If there's anything else that doesn't work (and I know some bugs that aren't listed here) please let me know. ;)
Have a look at the directive example. It shows how you can change the language at runtime :)
Hello. In my case it is't work :(
OK, could you please tell us, what exactly does not work?
Are your HTML files on a server or did you just open a file directly (file:\\\
)?
Regards, Andre
I'm trying to integrate ng-i18next into my app and I have hit a problem: I can not change the language from within a controller. I want to allow my user to click on the language code and change the UI language based on that action. I'm using the directive based approach. Is such a functionality possible?