$(document).ready(function() {
$('#example').dataTable();
$('<div />').addClass('UnSelectAllButton').css({'float' : 'left'}).attr({'id' : 'UnSelectAllButtons'}).prependTo($('#example_filter'));
$('<button />').attr({
'id' : 'deSelectAll'
})
.html('Deselect All')
.appendTo($('#UnSelectAllButtons'));
$('<button />').attr({
'id' : 'selectAll'
})
.html('Select All')
.appendTo($('#UnSelectAllButtons'));
$('#deSelectAll').click( function () {
alert( 'Deselect all.');
});
$('#selectAll').click( function () {
alert( 'Select all.');
});
});
You can test it out here.
i just needed it, thanks
ReplyDelete