count of selected radio buttons in jquery

后端 未结 3 1561
猫巷女王i
猫巷女王i 2021-02-20 06:38

suppose I have groups of radio buttons like so:

 
3条回答
  •  被撕碎了的回忆
    2021-02-20 07:16

    You could do:

     var numberOfCheckedRadio = $('input:radio:checked').length
     //this gives you the total of checked radio buttons on the page
    

提交回复
热议问题