add questioning
This commit is contained in:
@@ -38,8 +38,11 @@ if (defined('PHP_OS') && eregi('win', PHP_OS)) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// MySQL Version
|
// MySQL Version
|
||||||
$result = @mysql_query('SELECT VERSION() AS version');
|
|
||||||
|
if (!empty($server)){
|
||||||
|
$result = mysql_query('SELECT VERSION() AS version');
|
||||||
if ($result != FALSE && @mysql_num_rows($result) > 0) {
|
if ($result != FALSE && @mysql_num_rows($result) > 0) {
|
||||||
|
$result = mysql_query('SELECT VERSION() AS version') or mysql_die();
|
||||||
$row = mysql_fetch_array($result);
|
$row = mysql_fetch_array($result);
|
||||||
define('MYSQL_MAJOR_VERSION', (double)substr($row['version'], 0, 4));
|
define('MYSQL_MAJOR_VERSION', (double)substr($row['version'], 0, 4));
|
||||||
define('MYSQL_MINOR_VERSION', (double)substr($row['version'], 5));
|
define('MYSQL_MINOR_VERSION', (double)substr($row['version'], 5));
|
||||||
@@ -54,5 +57,9 @@ if ($result != FALSE && @mysql_num_rows($result) > 0) {
|
|||||||
define('MYSQL_MINOR_VERSION', 0);
|
define('MYSQL_MINOR_VERSION', 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
else{
|
||||||
|
define('MYSQL_MAJOR_VERSION', 3.21);
|
||||||
|
define('MYSQL_MINOR_VERSION', 0);
|
||||||
|
}
|
||||||
?>
|
?>
|
||||||
|
Reference in New Issue
Block a user