Directly adding footer in JQuery DataTable -
i want directly add footer jquery datatable, body of table using dt.row.add() method. how possible without using footer callback method?
thanks.
datatables doesn't seem have api add footer dynamically, if that's want. checks presence of <tfoot>
element during initialization only.
to add footer dynamically:
destroy table destroy().
$('#example').datatable().destroy();
append
<tfoot><tr><th></th></tr></tfoot>
<table>
element making sure you're adding many<th></th>
elements there columns in table.re-initialize table same options:
$('#example').datatable({ /* options here */ });
Comments
Post a Comment