I'm building an e-commerce site. here's what im trying to do.
I'm building a page to view all of the data for the status that has not been confirm which is 0 . and i populate the data using loop and i add a checkbox to update to the status from 0 to 1. question is. how to update the value of the data row from the checkbox? how can i send the key to update the data row?
while($row = mysql_fetch_array($query))
{
$f1 = $row['BuyerName'];
$f2 = $row['BuyerEmail'];
$f3 = $row['BuyerAddress'];
$f4 = $row['TransactionID'];
$f5 = $row['ItemAmount'];
$f6 = $row['DateTime'];
?>
<tr>
<td><?php echo $f1 ?></td>
<td><?php echo $f2 ?></td>
<td><?php echo $f3 ?></td>
<td><?php echo $f4 ?></td>
<td><?php echo $f5 ?></td>
<td><?php echo $f6 ?></td>
<td><?php echo"<a href ='detail.php?TransactionID=$f4'>Butiran</a>";?></td>
<td>
<form>
<input type="checkbox" class="check" name="inputStatus" value="1"> Selesai
</form>
</td>
</tr>
<?php
} //while
?>
</table>
Aucun commentaire:
Enregistrer un commentaire