mirror of
https://github.com/vrana/adminer.git
synced 2025-08-09 08:06:59 +02:00
Remove nested array
This commit is contained in:
@@ -10,18 +10,18 @@ class AdminerEnumOption {
|
||||
|
||||
function editInput($table, $field, $attrs, $value) {
|
||||
if ($field["type"] == "enum") {
|
||||
$options = array("" => array());
|
||||
$options = array();
|
||||
$selected = $value;
|
||||
if (isset($_GET["select"])) {
|
||||
$options[""][-1] = lang('original');
|
||||
$options[-1] = lang('original');
|
||||
}
|
||||
if ($field["null"]) {
|
||||
$options[""][""] = "NULL";
|
||||
$options[""] = "NULL";
|
||||
if ($value === null && !isset($_GET["select"])) {
|
||||
$selected = "";
|
||||
}
|
||||
}
|
||||
$options[""][0] = lang('empty');
|
||||
$options[0] = lang('empty');
|
||||
preg_match_all("~'((?:[^']|'')*)'~", $field["length"], $matches);
|
||||
foreach ($matches[1] as $i => $val) {
|
||||
$val = stripcslashes(str_replace("''", "'", $val));
|
||||
|
Reference in New Issue
Block a user