≡
×
Plus
Manual
Examples
Reference
Download
Blog
Community
Support
paginator set default number to 10
paginator set default number to 10
bernhard
Posts: 2
Questions: 0
Answers: 0
July 2012
edited July 2012
in
Plug-ins
I use the paginator to paginate my table. There are a lot of rows in it. (2000+) I want to have the table by default paginated into 10 rows per page. but what happens is that all items are shown. How can I change this?
Replies
koosvdkolk
Posts: 169
Questions: 0
Answers: 0
July 2012
edited July 2012
Can you give us some code?
Did you set
bPaginate
to false? (which is wrong, it should be true)? You might also want to check iDisplayLength.
bernhard
Posts: 2
Questions: 0
Answers: 0
July 2012
('#thissorttable').dataTable( {
"bPaginate": true,
"bLengthChange": true,
"bFilter": true,
"bSort": true,
"bInfo": true,
"bAutoWidth": true,
"oLanguage": {
'sSearch': "",
'sZeroRecords': "Geen records gevonden",
"sLengthMenu": 'Bekijk '+
'10'+
'20'+
'30'+
'40'+
'50'+
'All'+
' '
}
} );
allan
Posts: 65,815
Questions: 1
Answers: 10,950
Site admin
July 2012
The default is 10 (see example on the home page: http://datatables.net/ ), so my guess is you have a script error. What does Firebug / Inspector say?
Allan
This discussion has been closed.
Replies
Did you set bPaginate to false? (which is wrong, it should be true)? You might also want to check iDisplayLength.
"bPaginate": true,
"bLengthChange": true,
"bFilter": true,
"bSort": true,
"bInfo": true,
"bAutoWidth": true,
"oLanguage": {
'sSearch': "",
'sZeroRecords': "Geen records gevonden",
"sLengthMenu": 'Bekijk '+
'10'+
'20'+
'30'+
'40'+
'50'+
'All'+
' '
}
} );
Allan