From 8ec812d97de321d8100f8e80ccad06cc36840e12 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Fr=C3=A9d=C3=A9ric=20Demians?= Date: Thu, 9 Feb 2012 11:03:34 +0100 Subject: [PATCH] Bug 7514 Choose OPAC language with URL parameter Signed-off-by: Katrin Fischer Tested: - with and without cookie set - different language codes http://.../cgi-bin/koha/opac-changelanguage.pl?language=de-DE will directly open the German OPAC. http://.../cgi-bin/koha/opac-changelanguage.pl?language=en will directly open the English OPAC. Signed-off-by: Paul Poulain --- opac/opac-changelanguage.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/opac/opac-changelanguage.pl b/opac/opac-changelanguage.pl index 1c3ee8e6cd..8692a6318b 100755 --- a/opac/opac-changelanguage.pl +++ b/opac/opac-changelanguage.pl @@ -22,7 +22,7 @@ use CGI; my $query = new CGI; my $language = $query->param('language'); -my $url = $query->referer(); +my $url = $query->referer() || '/'; # warn "Language : $query // $language // $url"; C4::Templates::setlanguagecookie( $query, $language, $url ); -- 2.39.5