Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Checkbox list with same name do not allow multiple selection #1851
The checkboxradio plugin treats a check box list with same value for the name attribute for the check boxes as radio buttons. Hence the plugin allows to select only one item whereas the expected behavior is to select multiple items. When the checkbox list is rendered as native controls they behave as expected.
To allow multiple selection, as a workaround we have to provide unique names for each checkbox. This adds a extra amount of work at the server side to gather all the selected checkboxes values. If they are posted with same names, we can use the name to get a comma separated list of selected checkboxes values.
Please work on this.
pushed a commit
Jun 27, 2011
I have created a jsfiddle where I have two sets of checkboxes (one 'normal' and one in a control group): http://jsfiddle.net/agcolom/Au9zy/8/
All checkboxes in the 1st set have the same name. All checkboxes in the 2nd set have the same name (but a different name than the checkboxes in the 1st set). In both sets, I can select none, one or many checkboxes.
So unless I misunderstood what the issue was, it looks fixed :-)