1
0
mirror of https://github.com/vrana/adminer.git synced 2025-08-18 04:11:27 +02:00

Order by first index in Editor by default

Flush before SHOW DATABASES by default

git-svn-id: https://adminer.svn.sourceforge.net/svnroot/adminer/trunk@923 7c3ca157-0c34-0410-bff1-cbf682f78f5c
This commit is contained in:
jakubvrana
2009-07-28 11:04:49 +00:00
parent e1abcda063
commit a3d2266a9c
4 changed files with 17 additions and 15 deletions

View File

@@ -423,8 +423,6 @@ class Adminer {
function navigation($missing) {
global $SELF, $dbh;
if ($missing != "auth") {
ob_flush();
flush();
$databases = get_databases();
?>
<form action="" method="post">

View File

@@ -152,11 +152,15 @@ function connect() {
return $dbh->error;
}
function get_databases() {
function get_databases($flush = true) {
// SHOW DATABASES can take a very long time so it is cached
$return = &$_SESSION["databases"][$_GET["server"]];
if (!isset($return)) {
$return = get_vals("SHOW DATABASES");
if ($flush) {
ob_flush();
flush();
}
}
return $return;
}