Yet another ungly fix concerning the missing mysql_get_client_info() function.

This commit is contained in:
Alexander M. Turek
2004-02-29 22:31:25 +00:00
parent d2debd7c20
commit 4c1117e937
2 changed files with 9 additions and 3 deletions

View File

@@ -8,6 +8,8 @@ $Source$
2004-02-29 Alexander M. Turek <howcanisleepwithyourvoiceinmyhead@derrabus.de> 2004-02-29 Alexander M. Turek <howcanisleepwithyourvoiceinmyhead@derrabus.de>
* tbl_select.php: Fixed bug #887505 (PMA does not add MySQL charsets to * tbl_select.php: Fixed bug #887505 (PMA does not add MySQL charsets to
WHERE clauses). WHERE clauses).
* libraries/dbi/mysql.dbi.lib.php: Yet another ungly fix concerning the
missing mysql_get_client_info() function.
2004-02-27 Michal Cihar <imback@cihar.com> 2004-02-27 Michal Cihar <imback@cihar.com>
* config.inc.php, libraries/config_import.lib.php, * config.inc.php, libraries/config_import.lib.php,

View File

@@ -23,9 +23,13 @@ if (!@function_exists('mysql_connect')) {
// MySQL client API // MySQL client API
if (!defined('PMA_MYSQL_CLIENT_API')) { if (!defined('PMA_MYSQL_CLIENT_API')) {
$client_api = explode('.', mysql_get_client_info()); if (function_exists('mysql_get_client_info')) {
define('PMA_MYSQL_CLIENT_API', (int)sprintf('%d%02d%02d', $client_api[0], $client_api[1], intval($client_api[2]))); $client_api = explode('.', mysql_get_client_info());
unset($client_api); define('PMA_MYSQL_CLIENT_API', (int)sprintf('%d%02d%02d', $client_api[0], $client_api[1], intval($client_api[2])));
unset($client_api);
} else {
define('PMA_MYSQL_CLIENT_API', 32332); // always expect the worst...
}
} }
function PMA_DBI_connect($user, $password) { function PMA_DBI_connect($user, $password) {