From 3c36a3e1b27323a0b62ca73dfbf82ce54a6049f1 Mon Sep 17 00:00:00 2001 From: Franck Allimant Date: Sun, 26 Jan 2014 22:03:11 +0100 Subject: [PATCH] Language menu in the B.O to switch UI language on the fly. (see issue #183) --- core/lib/Thelia/Tools/URL.php | 3 +- templates/backOffice/default/admin-layout.tpl | 40 ++++++++++++++----- 2 files changed, 32 insertions(+), 11 deletions(-) diff --git a/core/lib/Thelia/Tools/URL.php b/core/lib/Thelia/Tools/URL.php index f50c7db27..cf593bf06 100644 --- a/core/lib/Thelia/Tools/URL.php +++ b/core/lib/Thelia/Tools/URL.php @@ -154,7 +154,8 @@ class URL $sepChar = strstr($base, '?') === false ? '?' : '&'; if ('' !== $queryString = rtrim($queryString, "&")) $queryString = $sepChar . $queryString; - return $base . $queryString; + + return rtrim($base, '&') . $queryString; } /** diff --git a/templates/backOffice/default/admin-layout.tpl b/templates/backOffice/default/admin-layout.tpl index 6876b5dd5..8775c60d1 100644 --- a/templates/backOffice/default/admin-layout.tpl +++ b/templates/backOffice/default/admin-layout.tpl @@ -67,16 +67,36 @@
{intl l='Version %ver' ver="{$THELIA_VERSION}"}