Hello Community,
there are two ways to change users display language.
Control Panel --> My Account --> Display Settings
If I change the language there, it's instantly changed and everything has the selected language.
Programmatically with:
1
2user = UserServiceUtil.getUserById(Long.parseLong(request.getUserPrincipal().getName()));
3user.setLanguageId(selectedLanguage);
4UserLocalServiceUtil.updateUser(user);
This method works fine and persists the new user language. You can check it, when you have a look at control panel
The problem is: The portal is displayed with the selected language only after relogin! How can I achieve a portal reload with the new language settings?
LR 6.1.0 GA1 bundled with TomCat
BR Paul
Please sign in to flag this as inappropriate.