You don't need a widget to do that (demo):
$(function () {
var $table = $('table'),
checkboxColumn = 0;
// checkboxes updates
$table.find('tbody').on('change', 'input', function () {
var $cell = $(this).closest('td');
// only accept checkboxes in the first column
if ($cell[0].cellIndex === checkboxColumn) {
$cell.closest('tr').toggleClass('checked', this.checked);
// update cache with checkbox state
$table.trigger('updateCell', [ $cell[0] ]);
}
});
$table.find('thead input').on('change', function(){
var chk = this.checked;
$table.find('tbody tr').each(function(){
$(this).find('td:eq(' + checkboxColumn + ') input')
.prop('checked', chk)
.trigger('change');
});
});
var headers = {};
headers[checkboxColumn] = { sorter: false };
$table.tablesorter({
widgets: ['zebra'],
headers: headers
});
});
The above works with the original tablesorter.