How to get the checked value of multiple checkbox by name using Jquery ?

This post shows you that how to get the checked value of multiple checkbox by name property.
Let’s see an example.

<input type="checkbox"  name="checkbox_name[]" value="Checkbox_1">
<input type="checkbox"  name="checkbox_name[]" value="Checkbox_2">
<input type="checkbox"  name="checkbox_name[]" value="Checkbox_3">
<input type="checkbox"  name="checkbox_name[]" value="Checkbox_4">

Just execute the below script.

$('input[name="checkbox_name[]"]:checked').each(function(k,v){
alert(v.value);
});

If you want to get the value of multiple checkbox by name property.
Just execute the below script.

$('input[name="checkbox_name[]"]').each(function(k,v){
alert(v.value);
});
Please follow and like us:

Leave a Reply

Your email address will not be published. Required fields are marked *