Search code examples
jqueryjquery-pluginsicheck

check the checkboxes if it is not checked using icheck() in jquery


There are many check box.if the checkboxes are uncheck i have to checked.

$('.group_select').iCheck('uncheck').trigger(checked);

but that is not working.I tried this in jquery.


Solution

  • Why don't you just do this?

    if .group_select is a parent which contains all the checkboxes then you can do as below

    $('.group_select').find('input[type="checkbox"]').iCheck('check');
    

    if .group_select is the common classname given to your checkbox you can just write as below:

    $('.group_select').iCheck('check');