change iDisplayLength
change iDisplayLength
dskr
Posts: 1Questions: 1Answers: 0
Hi,
im sorry to ask this again, but it just isn't working properly...
When i try to change the iDisplayLength like this:
$(document).ready(function () {
$('#example').dataTable({
"iDisplayLength": 50
});
})
as explained here: https://datatables.net/forums/discussion/542/dynamically-change-idisplaylength
i just get the error message: "DataTables warning: table id=example - Cannot reinitialise DataTable. For more information about this error, please see http://datatables.net/tn/3"
This discussion has been closed.
Answers
As the error message says you have already initialised the DataTable somewhere else. You have two options:
page.len()
to dynamically set the page length.Allan