Reputation: 75
I have never encountered a problem like this before. When I click checkbox 1 it checks checkbox 1, but if I click on Checkbox 2 or 3 , they still check the first box.
<tr>
<td><input type="checkbox" id="checkbox65" class="css-checkbox med" />
<label for="checkbox65" class="css-label med elegant" name="avatar" value="image1"/></label></td>
<td><input type="checkbox" id="checkbox65" class="css-checkbox med" />
<label for="checkbox65" class="css-label med elegant" name="avatar" value="image2"/></label></td>
<td><input type="checkbox" id="checkbox65" class="css-checkbox med"/>
<label for="checkbox65" class="css-label med elegant" name="avatar" value="image3"></label></td>
</tr>
I am using checkbox styles from csscheckbox.com - idk if that is the issue. Any ideas?
Upvotes: 0
Views: 25
Reputation: 981
You should change the Ids of input checkboxes and for values of labels.
<tr>
<td><input type="checkbox" id="checkbox65" class="css-checkbox med" />
<label for="checkbox65" class="css-label med elegant" name="avatar" value="image1"/></label></td>
<td><input type="checkbox" id="checkbox66" class="css-checkbox med" />
<label for="checkbox66" class="css-label med elegant" name="avatar" value="image2"/></label></td>
<td><input type="checkbox" id="checkbox67" class="css-checkbox med"/>
<label for="checkbox67" class="css-label med elegant" name="avatar" value="image3"></label></td>
</tr>
This should fix.
Upvotes: 1