mirror of
https://github.com/vrana/adminer.git
synced 2025-08-09 08:06:59 +02:00
Use $connection->result
This commit is contained in:
@@ -1066,14 +1066,15 @@ if (!defined("DRIVER")) {
|
||||
return get_key_vals("SHOW VARIABLES");
|
||||
}
|
||||
|
||||
/** Checks if C-style escapes are supported
|
||||
/** Check if C-style escapes are supported
|
||||
* @return bool
|
||||
*/
|
||||
function is_c_style_escapes() {
|
||||
static $c_style = null;
|
||||
global $connection;
|
||||
static $c_style;
|
||||
if ($c_style === null) {
|
||||
$variables = get_key_vals("SHOW VARIABLES LIKE 'sql_mode'");
|
||||
$c_style = strpos($variables["sql_mode"], 'NO_BACKSLASH_ESCAPES') === false;
|
||||
$sql_mode = $connection->result("SHOW VARIABLES LIKE 'sql_mode'", 1);
|
||||
$c_style = (strpos($sql_mode, 'NO_BACKSLASH_ESCAPES') === false);
|
||||
}
|
||||
return $c_style;
|
||||
}
|
||||
|
@@ -888,10 +888,10 @@ AND typelem = 0"
|
||||
}
|
||||
|
||||
function is_c_style_escapes() {
|
||||
static $c_style = null;
|
||||
global $connection;
|
||||
static $c_style;
|
||||
if ($c_style === null) {
|
||||
$vals = get_vals("SHOW standard_conforming_strings");
|
||||
$c_style = $vals[0] == "off";
|
||||
$c_style = ($connection->result("SHOW standard_conforming_strings") == "off");
|
||||
}
|
||||
return $c_style;
|
||||
}
|
||||
|
Reference in New Issue
Block a user