I'm trying to use a form to display a record from my database.
I am getting this error
Parse error: parse error, unexpected T_VARIABLE in c:\inetpub\wwwroot\cardguard\test\form test\input.php on line 19
the line in bold is line 19
here is my code:
<body>
<form name="form1" method="post" action="<?php echo $_SERVER['php_self']; ?>">
<p>Bank Name<br>
<input name="bank" type="text" id="bank">
<input type="submit" name="Submit" value="GO">
</p>
</form>
<?PHP
mysql_connect('localhost', 'root');
mysql_select_db('cardguard');
if (!IsSet($POST['bank'])
$query = "SELECT issure_name FROM cards WHERE issure_name = '$POST['bank']'";
$result = mysql_query($query);
if (mysql_errno()) die(mysql_error());
while ($row = mysql_fetch_row($result)) {
print ("$row[0]<br>\n");
}
else
$query = "SELECT issure_name FROM cards";
$result = mysql_query($query);
if (mysql_errno()) die(mysql_error());
while ($row = mysql_fetch_row($result)) {
print ("$row[0]<br>\n");
}
?>
</body>
thanks for the help