1
0
mirror of https://github.com/vrana/adminer.git synced 2025-08-21 21:55:43 +02:00

Print elapsed time in HTML instead of SQL command comment

This commit is contained in:
Jakub Vrana
2014-03-07 09:33:37 -08:00
parent d9fe03e1b4
commit 6a3ede75f6
10 changed files with 46 additions and 35 deletions

View File

@@ -128,8 +128,8 @@ ORDER BY ORDINAL_POSITION", null, "") as $row) { //! requires MySQL 5
}
}
function selectQuery($query) {
return "<!--\n" . str_replace("--", "--><!-- ", $query) . "\n-->\n";
function selectQuery($query, $time) {
return "<!--\n" . str_replace("--", "--><!-- ", $query) . "\n($time)\n-->\n";
}
function rowDescription($table) {
@@ -425,8 +425,8 @@ ORDER BY ORDINAL_POSITION", null, "") as $row) { //! requires MySQL 5
return "";
}
function messageQuery($query) {
return " <span class='time'>" . @date("H:i:s") . "</span><!--\n" . str_replace("--", "--><!-- ", $query) . "\n-->";
function messageQuery($query, $time) {
return " <span class='time'>" . @date("H:i:s") . "</span><!--\n" . str_replace("--", "--><!-- ", $query) . "\n" . ($time ? "($time)\n" : "") . "-->";
}
function editFunctions($field) {