Switch site language when selecting translated pages
When selecting a translated page in a different language, Tiki should switch the entire site-wide language to that language. Doesn't it make sense that if a user wants to read a page in ES, that they would also want the entire site interface to be in ES, too.
I've hacked together a modification of the Translation module to add the &switchLang parameter when clicking a BETTER or EQUIVALENT translation. You can see it here:
http://twbasics.keycontent.org/tiki-index.php
- From the English page, click the Spanish (ES) equivalent translation.
- Tiki returns the following URL: http://twbasics.keycontent.org/tiki-index.php?page=HomePage%2C%20es&switchLang=es
Some problems I've encountered:
- Notice that although the English translation is show as "equivalent", the language code (EN) is missing.
- If you use the Language selector to choose a different language (for example GERMAN), the site interface remains in SPANISH, regardless of the selection.
I think this is because the switchLang stores a session parameter that overrides other language selections.
-R
BTW, I added this as a tracker item, too.