Add / Remove Class
Add / Remove Class
Hi guys,
Thank you for that;
How can I add and remove classes using only the options ?
Because I use more than one datatable in a page.
I want to give the styles of the tables separately.
e.g I want to make this code using options.
$('.paginate_button').removeClass('paginate_button').addClass('btn btn-success').css('margin-right','5px');
$('.current').removeClass('current').addClass('active');
$('.dt-buttons a').removeClass().addClass('btn btn-success').css('margin-right', '5px');
Replies
Currently there isn't a public API for that, sorry. The classes are effectively shared between all tables.
Allan