This message was never displayed

This commit is contained in:
Marc Delisle
2011-05-05 06:31:15 -04:00
parent 69646655d3
commit 06d6b87e5b

View File

@@ -18,25 +18,29 @@ $cfgRelation = PMA_getRelationsParam();
/** /**
* A query has been submitted -> execute it, else display the headers * A query has been submitted -> (maybe) execute it
*/ */
$message_to_display = false;
if (isset($_REQUEST['submit_sql']) && ! empty($sql_query)) { if (isset($_REQUEST['submit_sql']) && ! empty($sql_query)) {
if (! preg_match('@^SELECT@i', $sql_query)) {
$message_to_display = true;
} else {
$goto = 'db_sql.php'; $goto = 'db_sql.php';
require './sql.php'; require './sql.php';
exit; exit;
} else { }
}
$sub_part = '_qbe'; $sub_part = '_qbe';
require './libraries/db_common.inc.php'; require './libraries/db_common.inc.php';
$url_query .= '&goto=db_qbe.php'; $url_query .= '&goto=db_qbe.php';
$url_params['goto'] = 'db_qbe.php'; $url_params['goto'] = 'db_qbe.php';
require './libraries/db_info.inc.php'; require './libraries/db_info.inc.php';
}
if (isset($_REQUEST['submit_sql']) if ($message_to_display) {
&& ! preg_match('@^SELECT@i', $sql_query)) {
PMA_Message::error(__('You have to choose at least one column to display'))->display(); PMA_Message::error(__('You have to choose at least one column to display'))->display();
} }
unset($message_to_display);
/** /**
* Initialize some variables * Initialize some variables