Dear experties,
I have a problem to insert checkbox value that called from database. How can I identify each checkbox's value?
This is my code to show the checkbox. Dont know how to post the value to insert into database if checked.
Please give me idea to solve it. Thank you.
<?php
$sql="SELECT * FROM dept_receiver";
$result=mysql_query($sql);
// run through the results from the database, generating the checkboxes
while ($row = mysql_fetch_assoc($result)) {
echo "\n\t";
echo "<input id='{$row['rcvr_id']}' type='checkbox' name='rcvr[]' value='{$row['rcvr_id']}'>{$row['rcvr_name']}";
}
?>