This is a pretty simple script, parses with no errors, but I can't get any output after the </form> tag outside of the php code. I can break the code after it using bad syntax, so I know it's getting parsed, but as the comment below shows, I can't even execute a lousy echo. Any ideas ?
<html>
<head>
<title>DB Interface</title>
</head>
<body>
<form action = "<?=$_SERVER['PHP_SELF']?>" method = "POST">
<textarea name = "querycontents" rows = "5" cols = "20">
Enter Query Here
</textarea>
<input type = "submit" name = "submitquery" value = "SUBMIT" \>
</form>
<?php $dbcnx = @mysql_db_connect("localhost", "ODBC", "");
echo "test 1";//this won't show up.. why ?
if (!$dbcnx) {
echo ("<p>Unable to connect to the Database</p>");
exit();
}
elseif (! @mysql_select_db("members")) {
echo "<p>Unable to select database</p>";
exit();
}
elseif ($_POST['submitquery'] == "SUBMIT" ){
$sql = $_POST['querycontents'];
if (@mysql_query($sql)){
echo "<p>Query successful.</p>";
} else {
echo "<p>Error while performing query:" . mysql_error() . "</p>";
}
}
?>
</body>
</html>