Please help, Im trying to search for mysql records using an html form to display the corresponding record for the entered primary key. Here's my html form:
<td><input type="submit" name="Submit" value="Search"></td>
And here's the new.php form action:,
mysql_select_db("Hospital", $con);
$result = mysql_query("SELECT HOSPNUM FROM t2 WHERE FIRSTNAME='{$_POST["fname"]}'");
while($row = mysql_fetch_array($result))
{
<input name="hnum" type="text" id="hospnum" value="<?php echo $row['HOSPNUM']; ?>" />
}
mysql_close($con);
?>
Nasıl ben giriş Fname ve ardından arama butonuna tıkladığınızda html inputbox içinde hospnum görüntülemek için alabilirim.