|
i am a form with checkboxes, i loop them and put values in a query.
ok here is the problem , initaly there were 4 checkboxes "check[]"
i used :
foreach($_POST['select'] as $key=>$value) {
$query = "insert into tblenroll values (NULL, '" . $this->cleantext($who) . "','" . $this->cleantext($value) . "','" . $this->cleantext($listmenu) . "')";
$result = $dbunique->query ( $query );
}
THis worked ok , now i had to add a new colum to tblenroll and fill it in with a "1 or 2"
each checkbox will have a status select ex-> checkbox[], listmenu[]
so i need to loop though listmenu[] which will bring the value to $listmenu.
But.... i cant get it right!!!
|