Number of rows

Number of rows

umar482umar482 Posts: 2Questions: 1Answers: 0

Hello,

I am generating a table from php, no ajax involved. All i want is to display five rows and not the usual ten. This should have worked but i still get ten rows per page

if ( ! $.fn.DataTable.isDataTable( '#table' ) ) {
jQuery('#table').dataTable({
"bSort": false,
"pageLength": 5
});
}

Answers

  • shickeyshickey Posts: 18Questions: 1Answers: 0

    Can you post an example as shown in the stickied post?

  • umar482umar482 Posts: 2Questions: 1Answers: 0

    "iDisplayLength" : 5 worked for me. I have the table in a bootstrap modal and a lot of plugins on the same page, so it's probably something on my side

This discussion has been closed.