$('#btnSelectAll').click(function() {
$('.inputchbox').attr('checked', true);
});
$('#btnCancel').click(function() {
$('fieldset:not(:checked)').find("input,select,textarea").removeAttr('disabled');
});
On cancel I need to enable only the checkboxes which are checked? Can I use something like this?
On selectall button I am selecting all the checkboxes from my fieldset
but here I need to select only the enabled checkboxes and the not disabled checkboxes..
So checkboxes are disabled on my fieldset on the load it self?
How to exclude disabled checkboxes?
You can use an intervening filter:
edit — or you can do like @sAc says and use a filter selector; I have a mental block about those so you probably shouldn’t listen to me. It’s probably something that happened in my childhood.