summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenjamin Franzke <benjaminfranzke@googlemail.com>2012-11-24 14:42:12 +0100
committerBenjamin Franzke <benjaminfranzke@googlemail.com>2012-11-24 14:42:12 +0100
commit288b4c1b9eacd9afd80f2a5ab860981e6386d03e (patch)
tree8bfd2356fb916a9cbfeff0a348bdcfd61332ce22
parent1792444a81b019a7a842d2ba5e869ca4d3ae91b2 (diff)
downloadsqltutor-plugin-288b4c1b9eacd9afd80f2a5ab860981e6386d03e.tar.gz
sqltutor-plugin-288b4c1b9eacd9afd80f2a5ab860981e6386d03e.tar.bz2
sqltutor-plugin-288b4c1b9eacd9afd80f2a5ab860981e6386d03e.zip
sqlbox: Print query only if one was supplied
-rw-r--r--sqlbox/view.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/sqlbox/view.php b/sqlbox/view.php
index 1f7cf41..eedca2b 100644
--- a/sqlbox/view.php
+++ b/sqlbox/view.php
@@ -81,8 +81,8 @@ $data = $form->get_data();
$correct = true;
-echo $OUTPUT->heading('SQL Query: '.$data->sqlbox_query);
if (isset($data->sqlbox_query)) {
+ echo $OUTPUT->heading('SQL Query: '.$data->sqlbox_query);
$db = pg_connect("host=localhost dbname=sqlbox user=sqlbox password=foobar");
if (!$db)
error("Failed to connect to sqlbox db");