aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb
diff options
context:
space:
mode:
authorMatt Friedman <maf675@gmail.com>2014-05-02 12:08:35 -0700
committerMatt Friedman <maf675@gmail.com>2014-05-02 12:08:35 -0700
commit78325736b1560c17713b5207c53fe0af582fab0b (patch)
tree63fbd350476aaff4e75ff395570dc2ea9cd56068 /phpBB/phpbb
parent42c60c6a9fcc7a4e6124257c3547eae0d34998ba (diff)
downloadforums-78325736b1560c17713b5207c53fe0af582fab0b.tar
forums-78325736b1560c17713b5207c53fe0af582fab0b.tar.gz
forums-78325736b1560c17713b5207c53fe0af582fab0b.tar.bz2
forums-78325736b1560c17713b5207c53fe0af582fab0b.tar.xz
forums-78325736b1560c17713b5207c53fe0af582fab0b.zip
[ticket/12254] Use a cookie instead of SID to store language selection
PHPBB3-12254
Diffstat (limited to 'phpBB/phpbb')
-rw-r--r--phpBB/phpbb/user.php8
1 files changed, 2 insertions, 6 deletions
diff --git a/phpBB/phpbb/user.php b/phpBB/phpbb/user.php
index 628ddd8e59..c2dcc9db7a 100644
--- a/phpBB/phpbb/user.php
+++ b/phpBB/phpbb/user.php
@@ -80,16 +80,12 @@ class user extends \phpbb\session
}
else
{
- $change_lang = $request->variable('language', '');
+ $change_lang = $request->variable($config['cookie_name'] . '_lang', '', true, \phpbb\request\request_interface::COOKIE);
if ($change_lang)
{
- global $SID, $_EXTRA_URL;
-
$use_lang = basename($change_lang);
$user_lang_name = (file_exists($this->lang_path . $use_lang . "/common.$phpEx")) ? $use_lang : basename($config['default_lang']);
$this->data['user_lang'] = $user_lang_name;
- $SID .= '&amp;language=' . $user_lang_name;
- $_EXTRA_URL[] = 'language=' . $user_lang_name;
}
else
{
@@ -203,7 +199,7 @@ class user extends \phpbb\session
$style_id = $style_request;
$SID .= '&amp;style=' . $style_id;
- $_EXTRA_URL[] = 'style=' . $style_id;
+ $_EXTRA_URL = array('style=' . $style_id);
}
else
{