I have a big div element and there are multiple div and input (checkbox type) tags inside of it. I want to check that if all checkboxes are checked or no. I try the following JQuery snippet to refer to all checkboxes inside the div:
$('div#mainDiv-checkboxes input[type=checkbox]').each(function(){ //my logic });
but it doesn't get all checkboxes. What is the reliable jquery selector for this kind of situation? there is no order for the position of input elements in my page. I mean there can be everywhere inside of the main div.
Aucun commentaire:
Enregistrer un commentaire