1
0
mirror of https://github.com/vrana/adminer.git synced 2025-08-16 11:34:10 +02:00

Move <h1> to $adminer->navigation

git-svn-id: https://adminer.svn.sourceforge.net/svnroot/adminer/trunk@1118 7c3ca157-0c34-0410-bff1-cbf682f78f5c
This commit is contained in:
jakubvrana
2009-09-19 20:16:15 +00:00
parent 4b81c92582
commit d3227c963f
4 changed files with 58 additions and 32 deletions

View File

@@ -348,6 +348,15 @@ ORDER BY ORDINAL_POSITION"); //! requires MySQL 5
}
function navigation($missing) {
global $VERSION;
?>
<h1>
<a href="http://www.adminer.org/" id="h1"><?php echo $this->name(); ?></a>
<span class="version"><?php echo $VERSION; ?></span>
<a href="http://www.adminer.org/editor/#download" id="version"><?php echo (version_compare($VERSION, $_COOKIE["adminer_version"]) < 0 ? h($_COOKIE["adminer_version"]) : ""); ?></a>
</h1>
<?php
echo (isset($_COOKIE["adminer_version"]) ? "" : "<script type='text/javascript'>verify_version();</script>\n");
if ($missing != "auth") {
?>
<form action="" method="post">
@@ -357,17 +366,21 @@ ORDER BY ORDINAL_POSITION"); //! requires MySQL 5
</p>
</form>
<?php
if ($missing != "db") {
$table_status = table_status();
if (!$table_status) {
echo "<p class='message'>" . lang('No tables.') . "\n";
} else {
echo "<p id='tables'>\n";
foreach ($table_status as $row) {
$name = $this->tableName($row);
if (isset($row["Engine"]) && strlen($name)) { // ignore views and tables without name
echo "<a href='" . h(ME) . 'select=' . urlencode($row["Name"]) . "'>$name</a><br>\n";
}
$this->printTables($missing);
}
}
function printTables($missing) {
if ($missing != "db") {
$table_status = table_status();
if (!$table_status) {
echo "<p class='message'>" . lang('No tables.') . "\n";
} else {
echo "<p id='tables'>\n";
foreach ($table_status as $row) {
$name = $this->tableName($row);
if (isset($row["Engine"]) && strlen($name)) { // ignore views and tables without name
echo "<a href='" . h(ME) . 'select=' . urlencode($row["Name"]) . "'>$name</a><br>\n";
}
}
}