分页控制外面的datatable [英] Pagination control outside datatable
本文介绍了分页控制外面的datatable的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
< div>
之外,sDom就像 < div class =pagination> pagination< / div>
到目前为止,我发现如何复制它看起来像:
fnInitComplete:function(oSettings){
var $ pagination = $('。dataTables_paginate')clone(true,true)
$('。navbar-inner')。append($ pagination);
}
有没有办法?
解决方案
当然 - 这里是您的解决方案
$(document).ready(function(){
$(#example)。dataTable();
//$(\"#NewPaginationContainer\").append($(\".dataTables_paginate\").clone(true));
$(#NewPaginationContainer)。append($(。dataTables_paginate)) ;
});
I am generating a datable with standard options, but I want to move the pagination control to another <div>
outside sDom like
<div class="pagination">pagination</div>
So far I found how to copy it looks like:
"fnInitComplete": function(oSettings){
var $pagination = $('.dataTables_paginate').clone(true, true);
$('.navbar-inner').append($pagination);
}
Is there a way to do it?
解决方案
Sure - here's your solution
$(document).ready(function() {
$("#example").dataTable();
//$("#NewPaginationContainer").append($(".dataTables_paginate").clone(true));
$("#NewPaginationContainer").append($(".dataTables_paginate"));
} );
这篇关于分页控制外面的datatable的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文