Product Spotlight
Select All CheckBoxes in a Table Column With and Without jQuery Plugin Demo
<< Back to Post
Select All CheckBoxes in a Table Column With and Without jQuery Plugin Demo
Standard jQuery to Select All CheckBoxes
$("#tableOne thead tr th:first input:checkbox").click(function() {
var checkedStatus = this.checked;
$("#tableOne tbody tr td:first-child input:checkbox").each(function() {
this.checked = checkedStatus;
});
});
selectAllRows Plugin Used with no Options
$("#tableTwo").selectAllRows();
selectAllRows Plugin with Last Column Option Used
$("#tableThree").selectAllRows({ column: 'last' });
selectAllRows Plugin with Column Number, Non Defaulted Tooltips Options and .css to Show Chaining Still Works
$("#tableFour").selectAllRows({
column: '2',
selectTip: 'Select All Students',
unselectTip: 'Un-Select All Students'
})
.css("border-width", "10px");