admin管理员组文章数量:1134247
How do you remove the "Showing 1 of N entries" line of text on a dataTable (that is when using the javascript library dataTables? I think I was looking for something along these lines...
$('#example').dataTable({
"showNEntries" : false
});
Pretty sure this is a simple one, but cannot seem to find it in the docs.
How do you remove the "Showing 1 of N entries" line of text on a dataTable (that is when using the javascript library dataTables? I think I was looking for something along these lines...
$('#example').dataTable({
"showNEntries" : false
});
Pretty sure this is a simple one, but cannot seem to find it in the docs.
Share Improve this question edited Jul 6, 2017 at 5:55 micstr 5,2068 gold badges50 silver badges77 bronze badges asked Oct 17, 2013 at 22:12 nickLnickL 1,5762 gold badges10 silver badges16 bronze badges5 Answers
Reset to default 332You can remove it with the bInfo
option (http://datatables.net/usage/features#bInfo)
$('#example').dataTable({
"bInfo" : false
});
Update:
Since Datatables 1.10.* this option can be used as info
, bInfo
still works in current nightly build (1.10.10).
try this for hide
$('#table_id').DataTable({
"info": false
});
and try this for change label
$('#table_id').DataTable({
"oLanguage": {
"sInfo" : "Showing _START_ to _END_ of _TOTAL_ entries",// text you want show for info section
},
});
If you also need to disable the drop-down (not to hide the text) then set the lengthChange
option to false
$('#datatable').dataTable( {
"lengthChange": false
} );
Works for DataTables 1.10+
Read more in the official documentation
Now, this seems to work:
$('#example').DataTable({
"info": false
});
it hides that div
, altogether
It is Work for me:
language:{"infoEmpty": "No records available",}
本文标签: javascriptHow to hide quotShowing 1 of N Entriesquot with the dataTablesjs libraryStack Overflow
版权声明:本文标题:javascript - How to hide "Showing 1 of N Entries" with the dataTables.js library - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1736790129a1953050.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论