1
0
mirror of https://github.com/vrana/adminer.git synced 2025-08-08 15:47:00 +02:00

Notices: Store maria into a declared variable

This commit is contained in:
Jakub Vrana
2025-03-24 05:58:35 +01:00
parent b89f628e40
commit 3dd1b41472
16 changed files with 27 additions and 23 deletions

View File

@@ -44,7 +44,7 @@ function getCmMode(el) {
if (match) {
const modes = {
js: 'application/json',
sql: 'text/x-<?php echo ($connection->maria ? "mariadb" : "mysql"); ?>',
sql: 'text/x-<?php echo ($connection->flavor == "maria" ? "mariadb" : "mysql"); ?>',
oracle: 'text/x-sql',
clickhouse: 'text/x-sql',
firebird: 'text/x-sql'

View File

@@ -8,7 +8,7 @@ if (isset($_GET["clickhouse"])) {
if (ini_bool('allow_url_fopen')) {
class Db {
public $extension = "JSON", $server_info, $errno, $error;
public $extension = "JSON", $flavor = '', $server_info, $errno, $error;
public $_db = 'default';
private $result, $url;

View File

@@ -9,7 +9,7 @@ if (isset($_GET["elastic"])) {
if (ini_bool('allow_url_fopen')) {
class Db {
public $extension = "JSON", $server_info, $errno, $error;
public $extension = "JSON", $flavor = '', $server_info, $errno, $error;
private $url;
/**

View File

@@ -14,6 +14,7 @@ if (isset($_GET["firebird"])) {
class Db {
public
$extension = "Firebird",
$flavor = '',
$server_info,
$affected_rows,
$errno,

View File

@@ -20,6 +20,7 @@ if (isset($_GET["imap"])) {
if (extension_loaded("imap")) {
class Db {
public $extension = "IMAP";
public $flavor = '';
public $error;
public $server_info = "?"; // imap_mailboxmsginfo() or imap_check() don't return anything useful
private $mailbox;

View File

@@ -8,7 +8,7 @@ if (isset($_GET["mongo"])) {
if (class_exists('MongoDB\Driver\Manager')) {
class Db {
public $extension = "MongoDB", $server_info = MONGODB_VERSION, $affected_rows, $error, $last_id;
public $extension = "MongoDB", $flavor = '', $server_info = MONGODB_VERSION, $affected_rows, $error, $last_id;
/** @var MongoDB\Driver\Manager */
public $_link;
public $_db, $_db_name;

View File

@@ -8,7 +8,7 @@ if (isset($_GET["simpledb"])) {
if (class_exists('SimpleXMLElement') && ini_bool('allow_url_fopen')) {
class Db {
public $extension = "SimpleXML", $server_info = '2009-04-15', $error, $timeout, $next, $affected_rows;
public $extension = "SimpleXML", $flavor = '', $server_info = '2009-04-15', $error, $timeout, $next, $affected_rows;
private $result;
function select_db($database) {