diff --git a/ChangeLog b/ChangeLog index 96a993fec..01bdaa251 100755 --- a/ChangeLog +++ b/ChangeLog @@ -19,6 +19,8 @@ $Source$ * libraries/display_select_lang.lib.php, libraries/select_lang.lib.php: Show native names of languages (RFE #1342726). * libraries/auth/cookie.auth.lib.php: Try to load mcrypt extension. + * Documentation.html, config.default.php, libraries/common.lib.php: + Configurable default connection collation (RFE #1025969). 2005-11-20 Sebastian Mendel * added test/theme.php: for testing themes diff --git a/Documentation.html b/Documentation.html index 3c7c2f960..dffd1b96d 100755 --- a/Documentation.html +++ b/Documentation.html @@ -1314,6 +1314,14 @@ GRANT SELECT, INSERT, UPDATE, DELETE ON <pma_db>.* TO 'pma'@'localhost'; this setting. +
$cfg['DefaultConnectionCollation'] string
+
+ Defines the default connection collation to use, if not + user-defined.
+ See the MySQL + documentation for list of possible values. +
+
$cfg['Lang'] string
Force: always use this language (must be defined in the diff --git a/config.default.php b/config.default.php index c53abb58a..38a85ee06 100644 --- a/config.default.php +++ b/config.default.php @@ -362,6 +362,9 @@ $cfg['PDFDefaultPageSize'] = 'A4'; // Default language to use, if not browser-defined or user-defined $cfg['DefaultLang'] = 'en-iso-8859-1'; +// Default connection collation (used for MySQL >= 4.1) +$cfg['DefaultConnectionCollation'] = 'utf8_unicode_ci'; + // Force: always use this language - must be defined in // libraries/select_lang.lib.php // $cfg['Lang'] = 'en-iso-8859-1'; diff --git a/libraries/common.lib.php b/libraries/common.lib.php index f18d8dfc8..f5c23418d 100644 --- a/libraries/common.lib.php +++ b/libraries/common.lib.php @@ -404,7 +404,9 @@ if (!is_dir($pmaThemeImage)) { if (isset($_COOKIE) && !empty($_COOKIE['pma_collation_connection']) && empty($_POST['collation_connection'])) { $collation_connection = $_COOKIE['pma_collation_connection']; } - +if (!isset($collation_connection)) { + $collation_connection = $GLOBALS['cfg']['DefaultConnectionCollation']; +} if ( ! defined( 'PMA_MINIMUM_COMMON' ) ) { /**