mirror of
https://github.com/vrana/adminer.git
synced 2025-08-18 12:21:24 +02:00
Move possible drivers and JUSH to Driver
This commit is contained in:
@@ -150,7 +150,7 @@ function auth_error($error) {
|
||||
if (isset($_GET["username"]) && !class_exists('Adminer\Db')) {
|
||||
unset($_SESSION["pwds"][DRIVER]);
|
||||
unset_permanent();
|
||||
page_header(lang('No extension'), lang('None of the supported PHP extensions (%s) are available.', implode(", ", $possible_drivers)), false);
|
||||
page_header(lang('No extension'), lang('None of the supported PHP extensions (%s) are available.', implode(", ", Driver::$possibleDrivers)), false);
|
||||
page_footer("auth");
|
||||
exit;
|
||||
}
|
||||
|
@@ -78,9 +78,7 @@ include "./include/adminer.inc.php";
|
||||
$adminer = (function_exists('adminer_object') ? adminer_object() : new Adminer);
|
||||
include "../adminer/drivers/mysql.inc.php"; // must be included as last driver
|
||||
|
||||
$config = driver_config();
|
||||
$possible_drivers = $config['possible_drivers'];
|
||||
$jush = $config['jush'];
|
||||
$jush = Driver::$jush;
|
||||
|
||||
define("SERVER", $_GET[DRIVER]); // read from pgsql=localhost
|
||||
define("DB", $_GET["db"]); // for the sake of speed and size
|
||||
|
@@ -23,6 +23,9 @@ function get_driver($id) {
|
||||
}
|
||||
|
||||
abstract class SqlDriver {
|
||||
static $possibleDrivers = array();
|
||||
static $jush; ///< @var string JUSH identifier
|
||||
|
||||
var $_conn;
|
||||
protected $types = array(); ///< @var array [$description => [$type => $maximum_unsigned_length, ...], ...]
|
||||
var $editFunctions = array(); ///< @var array of ["$type|$type2" => "$function/$function2"] functions used in editing, [0] - edit and insert, [1] - edit only
|
||||
|
Reference in New Issue
Block a user