From 06faef23e72052778de657348efea2ddabf92894 Mon Sep 17 00:00:00 2001 From: jakubvrana Date: Wed, 3 Sep 2008 09:35:12 +0000 Subject: [PATCH] Print SQL query by messages git-svn-id: https://adminer.svn.sourceforge.net/svnroot/adminer/trunk@480 7c3ca157-0c34-0410-bff1-cbf682f78f5c --- default.css | 2 ++ design.inc.php | 8 ++++++++ functions.inc.php | 3 ++- select.inc.php | 2 +- 4 files changed, 13 insertions(+), 2 deletions(-) diff --git a/default.css b/default.css index 53e4f07e..01c8e6df 100644 --- a/default.css +++ b/default.css @@ -12,6 +12,8 @@ th { background: #eee; } fieldset { display: inline; vertical-align: top; padding: .5em .8em; margin: 0 .5em .5em 0; border: 1px solid #999; } p { margin: 0 20px 1em 0; } img { vertical-align: middle; } +code { background-color: #eee; } +.js .hidden { display: none; } .error { color: red; background: #fee; padding: .5em .8em; } .message { color: green; background: #efe; padding: .5em .8em; } .char { color: #007F00; } diff --git a/design.inc.php b/design.inc.php index a0705412..d8a97a96 100644 --- a/design.inc.php +++ b/design.inc.php @@ -15,6 +15,14 @@ function page_header($title, $error = "", $breadcrumb = array(), $title2 = "") { +
' . lang('SQL command') . ""; + $id = "sql-" . count($_SESSION["messages"]); + $sql = " " . lang('SQL command') . "'; if ($execute && !$mysql->query($query)) { $error = htmlspecialchars($mysql->error) . $sql; return false; diff --git a/select.inc.php b/select.inc.php index cc353d6b..ef39cc2d 100644 --- a/select.inc.php +++ b/select.inc.php @@ -214,7 +214,7 @@ for (var i=0; > i; i++) { echo "\n"; $query = "SELECT " . ($select ? (count($group) < count($select) ? "SQL_CALC_FOUND_ROWS " : "") . implode(", ", $select) : "*") . " $from"; - echo "

" . htmlspecialchars($query) . " - " . lang('edit') . "

\n"; + echo "

" . htmlspecialchars($query) . " " . lang('Edit') . "

\n"; $result = $mysql->query($query); if (!$result) {