[Koha-patches] [PATCH] [SIGNED-OFF] Bug 8019 - Preserve language choice between Browser sessions

julian.maurice at biblibre.com julian.maurice at biblibre.com
Thu May 3 15:09:01 CEST 2012


From: Marc Veron <veron at veron.ch>

Language choice in Opac an Staff client was not preserved between Browser sessions.
Changed expiry date of cookie 'KohaOpacLanguage' from '' (= expire after session) to '+3y' (3 years from now)

To test:
- In a multilingual Koha istallation, choose a language.
- Log out, close all Browser instances. Go to login screen. Login should show up in same language as before.
- Repeat with other languages.

	modified:   C4/Templates.pm

Signed-off-by: Julian Maurice <julian.maurice at biblibre.com>
---
 C4/Templates.pm |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/C4/Templates.pm b/C4/Templates.pm
index d6e3ce4..47bda04 100644
--- a/C4/Templates.pm
+++ b/C4/Templates.pm
@@ -300,7 +300,7 @@ sub setlanguagecookie {
     my $cookie = $query->cookie(
         -name    => 'KohaOpacLanguage',
         -value   => $language,
-        -expires => ''
+        -expires => '+3y'
     );
     print $query->redirect(
         -uri    => $uri,
-- 
1.7.10



More information about the Koha-patches mailing list