Answers for "datatable show row number"

2

datatable count number of rows

var table = $('#example').DataTable();
table.rows().count();
Posted by: Guest on July-11-2020
1

datatable get row data

var table = $('#example').DataTable();

$('#example tbody').on( 'click', 'tr', function () {
    console.log( table.row( this ).data() );
} );
Posted by: Guest on August-05-2020

Browse Popular Code Answers by Language