I would say do something this:
while($myrow=mysql_fetch_array($result))
{
$a = $myrow["id"];
?>
<tr>
<td> <input type="text" name="food[<?php echo $a ?>]" value="<?php echo $myrow["food"]?>"/></td>
<td> <input type="text" name="price[<?php echo $a ?>]" value="<?php echo $myrow["price"]?>"/></td></td>
</tr>
<?php
}
Now, you'll get back two arrays, with the items' id numbers being the keys and the new value being the array value.
Then, you could loop through the arrays and update the DB:
for($i=0; isset($_POST['food'][$i]) && isset($_POST['price'][$i]); $i++) {
$query = 'UPDATE `choices` SET `food`=\'' . $_POST['food'][$i] . '\', `price`=\'' . $_POST['price'][$i] . '\' WHERE `id`=' . $i . ' LIMIT 1';
$exec = mysql_query($query);
}
Since you didn't do it in your code, I didn't in my example snippet, but I do hope you realize that you aren't validating/sanitizing any of the user-provided data, which means you are most likely leaving yourself vulnerable to a SQL injection attack. Google the term (or search the boards) for more info - you'll want to use [man]mysql_real_escape_string/man to clean up any user-provided data ($GET, $POST, etc.) before you use it in a query.