Hi, I am new to php and html, so I need some help with a problem: I am trying to make a form where you can select from a dropbox, but thae data from the dropbox should be retrieved from a sql database.
If I save the code bellow as php, the dropbox is created and retrieves the data from sql, but then the submit button (together with everything else I put after the while loop) disappeares. If I save it as a html file, the form and submit button works, but it doesn't retrieve any data from sql database.
Thanks
<form action="Techniques.php" method="post">
<p>Which Disease?
<select name="disease" >
<option value="" >--Select--</option>
<?php
require_once("dbconnect.php");
$sql = "SELECT * FROM diseases";
$result = mysql_query($sql)or die (mysql_error());
while($row = mysql_fetch_array($result) or die (mysql_error()))
{
?>
<option value="disease" ><?php echo($row['Disease']);?></option>
<?php
}
?>
</select>
</p>
input type="submit" value="Copmlete"/>
</form>