"aLengthMenu" is ignored
"aLengthMenu" is ignored
I created a datatable with property "aLengthMenu", but the dropdown is not created in UI. Below is a snippet of the definition:
var oTable = $('#table-people-course').dataTable( {
"sDom": "<''<'span6 pull-left'f>r>t<'row'<'span6'i><'span6'p>>",
"sPaginationType": "bootstrap",
"bLengthChange": false,
"bFilter": true,
"bInfo": false,
"iDisplayLength": 20,
"aLengthMenu": [[10, 25, 50, -1], [10, 25, 50, "All"]],
"rowHeight": "70px",
"aaSorting": [[ 0, "ASC" ]] ,
"oLanguage": {
"sLengthMenu": "MENU records per page"
},
...
I am using dataTable version 1.10.0
Any help is appreciated.
Thanks.
Answers
You are missing the l - Length changing parameter in your sDom.
Add that to your sDom and drop down will be displayed.