]> git.joonet.de Git - adminer.git/commitdiff
Prefill SQL query
authorjakubvrana <jakubvrana@7c3ca157-0c34-0410-bff1-cbf682f78f5c>
Mon, 1 Sep 2008 10:42:04 +0000 (10:42 +0000)
committerjakubvrana <jakubvrana@7c3ca157-0c34-0410-bff1-cbf682f78f5c>
Mon, 1 Sep 2008 10:42:04 +0000 (10:42 +0000)
git-svn-id: https://adminer.svn.sourceforge.net/svnroot/adminer/trunk@469 7c3ca157-0c34-0410-bff1-cbf682f78f5c

sql.inc.php

index 83e118c2a3cf9aed1ffe108405fd4c7007f8ac0c..3d841c3107be5cb831b06addfd71f0a60fc25fe0 100644 (file)
@@ -51,7 +51,7 @@ if (!$error && $_POST && is_string($query = (isset($_POST["query"]) ? $_POST["qu
 ?>
 
 <form action="" method="post">
-<p><textarea name="query" rows="20" cols="80" style="width: 98%;"><?php echo htmlspecialchars($_POST["query"]); ?></textarea></p>
+<p><textarea name="query" rows="20" cols="80" style="width: 98%;"><?php echo htmlspecialchars($_POST ? $_POST["query"] : $_GET["sql"]); ?></textarea></p>
 <p>
 <input type="hidden" name="token" value="<?php echo $token; ?>" />
 <input type="submit" value="<?php echo lang('Execute'); ?>" />