Am using datatables in my project. I have a checkbox on each row and contains paging and sorting. I am getting all the records at once. When I checked on check all it check all the check boxes. Am using the below code
Conclusion: If we select check box first time and then uncheck it and then do check all. Earlier checked checkboxes will not work.
Can you please help me in this.
$('#check_all').click( function(e) { var chkAll = $("#check_all").is(':checked'); if(chkAll) $('input', oTable.fnGetNodes()).attr('checked', this.checked); else $('input', oTable.fnGetNodes()).removeAttr('checked'); });When I uncheck and check again it does not checks the check boxes. But when do inspect element will see a property checked="checked", but check box is not showing as checked.
Conclusion: If we select check box first time and then uncheck it and then do check all. Earlier checked checkboxes will not work.
Can you please help me in this.