Abide cfg['Lang'] settings even if using MySQL > 4.1.x (bug #1266626).
This commit is contained in:
@@ -5,6 +5,10 @@ phpMyAdmin - Changelog
|
|||||||
$Id$
|
$Id$
|
||||||
$Source$
|
$Source$
|
||||||
|
|
||||||
|
2005-08-23 Michal Čihař <michal@cihar.com>
|
||||||
|
* libraries/database_interface.lib.php: Abide cfg['Lang'] settings even if
|
||||||
|
using MySQL > 4.1.x (bug #1266626).
|
||||||
|
|
||||||
2005-08-22 Michal Čihař <michal@cihar.com>
|
2005-08-22 Michal Čihař <michal@cihar.com>
|
||||||
* error.php, libraries/common.lib.php, libraries/sanitizing.lib.php:
|
* error.php, libraries/common.lib.php, libraries/sanitizing.lib.php:
|
||||||
Protect against possible XSS (bug #1265740), move input sanitizing to
|
Protect against possible XSS (bug #1265740), move input sanitizing to
|
||||||
|
@@ -156,8 +156,8 @@ function PMA_DBI_postConnect($link, $is_controluser = FALSE) {
|
|||||||
if (PMA_MYSQL_INT_VERSION >= 40100) {
|
if (PMA_MYSQL_INT_VERSION >= 40100) {
|
||||||
|
|
||||||
// If $lang is defined and we are on MySQL >= 4.1.x,
|
// If $lang is defined and we are on MySQL >= 4.1.x,
|
||||||
// we auto-switch the lang to its UTF-8 version (if it exists)
|
// we auto-switch the lang to its UTF-8 version (if it exists and user didn't force language)
|
||||||
if (!empty($GLOBALS['lang']) && (substr($GLOBALS['lang'], -5) != 'utf-8')) {
|
if (!empty($GLOBALS['lang']) && (substr($GLOBALS['lang'], -5) != 'utf-8') && !isset($GLOBALS['cfg']['Lang'])) {
|
||||||
$lang_utf_8_version = substr($GLOBALS['lang'], 0, strpos($GLOBALS['lang'], '-')) . '-utf-8';
|
$lang_utf_8_version = substr($GLOBALS['lang'], 0, strpos($GLOBALS['lang'], '-')) . '-utf-8';
|
||||||
if (!empty($GLOBALS['available_languages'][$lang_utf_8_version])) {
|
if (!empty($GLOBALS['available_languages'][$lang_utf_8_version])) {
|
||||||
$GLOBALS['lang'] = $lang_utf_8_version;
|
$GLOBALS['lang'] = $lang_utf_8_version;
|
||||||
|
Reference in New Issue
Block a user