How do I initialise specific tables without the search filter and length select menu?
Apparently it can be done with the sDom option, but the documentation is pretty bad and I can't understand exactly what I am supposed to do.
http://datatables.net/usage/options#sDom
To disable the "Show Entries" label, use "bInfo", example: "bFilter" is the search component, but are active by default. $(document). ready( function () { $('#example'). dataTable( { "bInfo": false } ); } );
There is a option called pageLength . You can set this for show only 5 entries.
ready(function () { $('. dataTables_filter input[type="search"]'). css( {'width':'350px','display':'inline-block'} ); }); And it worked perfectly!
You can set to false such properties during initialization of datatable:
"bFilter" : false, "bLengthChange": false
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With