Prefill .* when creating a new user
This commit is contained in:
parent
fd7e8cbaae
commit
841cbbb7d2
|
@ -113,7 +113,7 @@ if ($_POST) {
|
||||||
if ($old_pass != "") {
|
if ($old_pass != "") {
|
||||||
$row["hashed"] = true;
|
$row["hashed"] = true;
|
||||||
}
|
}
|
||||||
$grants[DB != "" && !isset($_GET["host"]) ? idf_escape(addcslashes(DB, "%_")) . ".*" : ""] = array();
|
$grants[(DB != "" && !isset($_GET["host"]) ? idf_escape(addcslashes(DB, "%_")) : "") . ".*"] = array();
|
||||||
}
|
}
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
@ -150,7 +150,7 @@ foreach (array(
|
||||||
foreach ($grants as $object => $grant) {
|
foreach ($grants as $object => $grant) {
|
||||||
$name = "'grants[$i][" . h(strtoupper($privilege)) . "]'";
|
$name = "'grants[$i][" . h(strtoupper($privilege)) . "]'";
|
||||||
$value = $grant[strtoupper($privilege)];
|
$value = $grant[strtoupper($privilege)];
|
||||||
if ($context == "Server Admin" && $object != (isset($grants["*.*"]) ? "*.*" : "")) {
|
if ($context == "Server Admin" && $object != (isset($grants["*.*"]) ? "*.*" : ".*")) {
|
||||||
echo "<td> ";
|
echo "<td> ";
|
||||||
} elseif (isset($_GET["grant"])) {
|
} elseif (isset($_GET["grant"])) {
|
||||||
echo "<td><select name=$name><option><option value='1'" . ($value ? " selected" : "") . ">" . lang('Grant') . "<option value='0'" . ($value == "0" ? " selected" : "") . ">" . lang('Revoke') . "</select>";
|
echo "<td><select name=$name><option><option value='1'" . ($value ? " selected" : "") . ">" . lang('Grant') . "<option value='0'" . ($value == "0" ? " selected" : "") . ">" . lang('Revoke') . "</select>";
|
||||||
|
|
Loading…
Reference in a new issue