I have a list of products as an output from a db table.
foreach ( $items as $r )
{
echo "<input type=text name=var1> ".$r->itemName."<input type=hidden name=itemID><br>";
}
I would like to update a value var1 for each product.
For one product I would just do:
query("UPDATE t1 SET value1='".$_POST['var1']."' WHERE id='".$_POST['itemID']."' LIMIT 1");
Not sure how can I do it all at once if I enter values for say 50 products...