Bug #692854: Never execute a query in (with/without) PHP code views, and display a
new "Execute query" link in this mode.
This commit is contained in:
@@ -5,6 +5,11 @@ phpMyAdmin - Changelog
|
||||
$Id$
|
||||
$Source$
|
||||
|
||||
2003-05-22 Garvin Hicking <me@supergarv.de>
|
||||
* sql.php3, libraries/common.lib.php3: Bug #692854: Never execute
|
||||
a query in (with/without) PHP code views, and display a new
|
||||
"Execute query" link in this mode.
|
||||
|
||||
2003-05-20 Garvin Hicking <me@supergarv.de>
|
||||
* index.php3: New rewrite of how the frameset is created
|
||||
(Patch item #738226 plus some <noframes> corrections).
|
||||
|
@@ -1447,6 +1447,15 @@ h1 {font-family: sans-serif; font-size: large; font-weight: bold}
|
||||
$php_link .= '1">' . $GLOBALS['strPhp'];
|
||||
}
|
||||
$php_link .= '</a>]';
|
||||
|
||||
if (isset($GLOBALS['show_as_php']) && $GLOBALS['show_as_php'] == '1') {
|
||||
$php_link .= ' [<a href="sql.php3'
|
||||
. $url_qpart
|
||||
. '&show_query=1'
|
||||
. '&sql_query=' . urlencode($local_query)
|
||||
. '">' . $GLOBALS['strRunQuery'] . '</a>]';
|
||||
}
|
||||
|
||||
} else {
|
||||
$php_link = '';
|
||||
} //show as php
|
||||
|
2
sql.php3
2
sql.php3
@@ -285,7 +285,7 @@ else {
|
||||
// E x e c u t e t h e q u e r y
|
||||
|
||||
// Only if we didn't ask to see the php code (mikebeck)
|
||||
if (!empty($GLOBALS['show_as_php']) || !empty($GLOBALS['validatequery'])) {
|
||||
if (isset($GLOBALS['show_as_php']) || !empty($GLOBALS['validatequery'])) {
|
||||
unset($result);
|
||||
$num_rows = 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user