I have this problem:
On a form i have some questions folowed by answears wich users can select by checkboxes. Each question has 5 answears( 5 checkboxes with identical names).
The checkboxes are grouped by names wich are attributed dynamicaly by php like this:
while ($row=mysql_fetch_array($rezultat))
{
print'<b>'.$row['question'].'</b>';
?>
<br>
<?print ''.$row['a'].'';?><input type="checkbox" name="question<?print ''.$row['id_question'].'';?>[]" value="a";>
<?print ''.$row['b'].'';?><input type="checkbox" name="question<?print ''.$row['id_question'].'';?>[]" value="b";> <br>
<?print ''.$row['c'].'';?><input type="checkbox" name="question<?print ''.$row['id_question'].'';?>[]" value="c";>
<?print ''.$row['d'].'';?><input type="checkbox" name="question<?print ''.$row['id_question'].'';?>[]" value="d";> <br>
<?print ''.$row['e'].'';?><input type="checkbox" name="question<?print ''.$row['id_question'].'';?>[]" value="e";> <br>
<br>
<hr>
<?
}
?>
=================
On the procesing form:
$sql="SELECT * FROM questions";
$result=mysql_query($sql);
$nr=mysql_num_rows($result);
for ($i=0 ;$i<$nr; $i++)
{
======================
How do i atach the $i variable at the end of $_get['question'] to cycle all the checkboxes arrays?
I hope you understand what im trying to explain.
Thank u!