Skip to content

[multilingual/login] Persist selected language in login after logging in + Language select in menubar#10356

Merged
driusan merged 3 commits intoaces:28.0-releasefrom
skarya22:2026_02_10_Global_Language_Change
Feb 18, 2026
Merged

[multilingual/login] Persist selected language in login after logging in + Language select in menubar#10356
driusan merged 3 commits intoaces:28.0-releasefrom
skarya22:2026_02_10_Global_Language_Change

Conversation

@skarya22
Copy link
Copy Markdown
Contributor

@skarya22 skarya22 commented Feb 10, 2026

Brief summary of changes

  • Adds language selector dropdown to all authenticated pages under my preferences
  • If changed, it updates the user's preferred language
  • Language selector on Login page now saves a local cookie, after logging in it gives priority to the cookie rather than the user preference
  • The cookie is cleared when you logout so that it defaults to LORIS default language
  • This solves two problems:
    • Changing languages when logged in was confusing as you had to open my_preferences, and then save, and exit the module to see the changes
    • Changing the language before logging in, and then logging in reverted the site to your preference, which was strange
image

Testing instructions (if applicable)

  1. Open a LORIS instance with languages in the language table
  2. On the login page, select a language that is not your user's language in my_preferences, then login and see that the language persists
  3. Go to my preferences without changing anything else, see that the my_preferences is still the other language, but the site is in the language you selected
  4. Hover over your account name in the menubar and change the language to something else, see that the language is changed in your user's preferences
  5. log out and see that the login page is in english again
  6. change the language to something else and login, and see that the site is in that language, but when you go to my preferences, it is still the language you changed it to in step 4

@github-actions github-actions Bot added Language: PHP PR or issue that update PHP code Language: Javascript PR or issue that update Javascript code Module: login PR or issue related to login module labels Feb 10, 2026
@skarya22 skarya22 changed the title 2026 02 10 global language change [multilingual/login] Persist selected language in login after logging in + Language select in menubar Feb 10, 2026
@skarya22 skarya22 added the Priority: High PR or issue should be prioritised over others for review and testing label Feb 10, 2026
@racostas racostas requested review from racostas and removed request for racostas February 18, 2026 18:39
Copy link
Copy Markdown
Contributor

@racostas racostas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Image Image

@racostas racostas added the Passed manual tests PR has been successfully tested by at least one peer label Feb 18, 2026
@racostas
Copy link
Copy Markdown
Contributor

@driusan , this one is looking good to me.
Thanks !

@driusan driusan merged commit 76252f4 into aces:28.0-release Feb 18, 2026
21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Language: Javascript PR or issue that update Javascript code Language: PHP PR or issue that update PHP code Module: login PR or issue related to login module Passed manual tests PR has been successfully tested by at least one peer Priority: High PR or issue should be prioritised over others for review and testing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants