How to count CheckBoxList using jQuery

I have a search for the following keyword but could not be found.

javascript CheckBoxList api

jquery CheckBoxList checked count

+4
source share
1 answer

Below is the total number of checked flags per page

var count = $(':checkbox:checked').length; 

If you want to limit it to only a specific CheckBoxList checklist, you can give this checkboxlist some class, and then:

 var count = $('.someClass :checkbox:checked').length; 
+6
source

All Articles