on this website people are able to select their favorite foods using checkboxes. the checkboxes are entered into the database as bools. for example, a row may be called "Steak" and it would have the value "0" if the user did not check it and "1" if it did.
what i want to do is display to the user on the home page of the website what they have already selected.
here is the code i have created, but it doesn't work. can anybody point me in the right direction? thanks.
<div align="center">
<table border="1">
<tr>
<th>Food</th>
</tr>
<tr>
<th>
<? $result = mysql_query("SELECT 'Steak' FROM foods WHERE
uid=".$_SESSION["uid"]);
$row = mysql_fetch_array($result);
if($row == 1)
{
print("Steak");
}
?>
</th>