From: jakubvrana Date: Thu, 25 Sep 2008 14:54:28 +0000 (+0000) Subject: Use elseif X-Git-Tag: v3.0.0~1022 X-Git-Url: https://git.joonet.de/?a=commitdiff_plain;h=bbfe44945cef3b7ec48d78519596c4b842b5db57;p=adminer.git Use elseif git-svn-id: https://adminer.svn.sourceforge.net/svnroot/adminer/trunk@496 7c3ca157-0c34-0410-bff1-cbf682f78f5c --- diff --git a/index.php b/index.php index 5810eabb..84cbb379 100644 --- a/index.php +++ b/index.php @@ -129,12 +129,9 @@ if (isset($_GET["download"])) { } } $message = lang('Tables have been truncated.'); - } else { - $result = queries((isset($_POST["optimize"]) ? "OPTIMIZE" : (isset($_POST["check"]) ? "CHECK" : (isset($_POST["repair"]) ? "REPAIR" : (isset($_POST["drop"]) ? "DROP" : "ANALYZE")))) . " TABLE " . implode(", ", array_map('idf_escape', $_POST["tables"]))); - if ($result) { - while ($row = $result->fetch_assoc()) { - $message .= htmlspecialchars("$row[Table]: $row[Msg_text]") . "
"; - } + } elseif ($result = queries((isset($_POST["optimize"]) ? "OPTIMIZE" : (isset($_POST["check"]) ? "CHECK" : (isset($_POST["repair"]) ? "REPAIR" : (isset($_POST["drop"]) ? "DROP" : "ANALYZE")))) . " TABLE " . implode(", ", array_map('idf_escape', $_POST["tables"])))) { + while ($row = $result->fetch_assoc()) { + $message .= htmlspecialchars("$row[Table]: $row[Msg_text]") . "
"; } } query_redirect(queries(), substr($SELF, 0, -1), $message, $result, false, !$result);