My code is like so:
$run = $dbcon->query("SELECT * FROM sometable");
while ($beef = $run->fetch_assoc()){
$theid = $beef['id'];
$patty = $beef['part'];
$current = POST['$theid'];
echo "<form name='$theid'>$patty</form>";
}
What this code is going to do is echo as many forms as I have rows in my sometable column part and show them all in my HTML (I suppose it bears mentioning that this is not proper HTML. Hopefully it is understood that for this example it is not the point).
Now, I would like to add something like $current = $_POST['$theid'] so that when making a db call, I can differentiate the various echo instances of the row's id. And I would like my $current variable to hold the correct instance of my id.
How might I approach this goal? Is a loop necessary? If so, how might that look?