Datatables - Open All Child Rows On Page Load
At the moment my table has child rows with a toggle to open each row in column 1. (I found this function online for managing the child rows) how can I change this so that child row
Solution 1:
Use the code below to show all child rows:
$("#example").DataTable().rows().every( function () {
var tr = $(this.node());
this.child(format(tr.data('child-value'))).show();
tr.addClass('shown');
});
See updated jsFiddle for code and demonstration.
See jQuery DataTables: How to expand/collapse all child rows for more examples and information.
Post a Comment for "Datatables - Open All Child Rows On Page Load"