Unify HTML for list of tables in Editor according to Adminer

This commit is contained in:
Peter Knut 2018-01-20 23:54:11 +01:00 committed by Jakub Vrana
parent fef1808288
commit 47734d8ff4

View file

@ -592,17 +592,19 @@ qsl('div').onclick = whisperClick;", "")
} }
function tablesPrint($tables) { function tablesPrint($tables) {
echo "<p id='tables'>"; echo "<ul id='tables'>";
echo script("mixin(qs('#tables'), {onmouseover: menuOver, onmouseout: menuOut});"); echo script("mixin(qs('#tables'), {onmouseover: menuOver, onmouseout: menuOut});");
foreach ($tables as $row) { foreach ($tables as $row) {
echo '<li>';
$name = $this->tableName($row); $name = $this->tableName($row);
if (isset($row["Engine"]) && $name != "") { // ignore views and tables without name if (isset($row["Engine"]) && $name != "") { // ignore views and tables without name
echo "<a href='" . h(ME) . 'select=' . urlencode($row["Name"]) . "'" echo "<a href='" . h(ME) . 'select=' . urlencode($row["Name"]) . "'"
. bold($_GET["select"] == $row["Name"] || $_GET["edit"] == $row["Name"], "select") . bold($_GET["select"] == $row["Name"] || $_GET["edit"] == $row["Name"], "select")
. " title='" . lang('Select data') . "'>$name</a><br>\n" . " title='" . lang('Select data') . "'>$name</a>\n"
; ;
} }
} }
echo "</ul>\n";
} }
function _foreignColumn($foreignKeys, $column) { function _foreignColumn($foreignKeys, $column) {