页面更改后,jQuery数据表内的Popover不起作用

页面更改后,jQuery数据表内的Popover不起作用,jquery,jquery-plugins,jquery-datatables,Jquery,Jquery Plugins,Jquery Datatables,我在我的页面上使用JQUERY数据表和Webui Popover插件。为中的元素实际指定的popover <small style=" color: #10336B;" class='codedescription' data-title="My Title" data-content='My Dynamic Content'><b>CODE 当第一页或数据表被绑定后,它工作正常。但是如果我们移动到datatable上的另一个页面,或者在页面更改后,pop

我在我的页面上使用JQUERY数据表和Webui Popover插件。为中的元素实际指定的popover

<small style=" color: #10336B;"  class='codedescription'  
data-title="My Title" data-content='My Dynamic Content'><b>CODE    
当第一页或数据表被绑定后,它工作正常。但是如果我们移动到datatable上的另一个页面,或者在页面更改后,popover停止工作。只有第一次初始化的流行音乐才起作用

因此,我尝试在Datatable页面更改事件中重新初始化popover插件,如下所示

$('#tbl_main').on('page.dt', function () {
    alert(55);
    $('.codedescription').webuiPopover({ closeable: false, trigger: 'hover', title: '', content: '', delay: { show: null, hide: 300} });
});

但当页面发生变化时,会显示警报,但弹出框不会显示在除第一页以外的任何页面中。是什么使得JQUERY数据表中的页面更改后弹出窗口不工作。

您应该使用
draw.dt
事件。在更新表的分页时触发,在dataTable完成绘制时触发

$('tbl_main')。关于('draw.dt',函数(){
...
});
$('#tbl_main').on('page.dt', function () {
    alert(55);
    $('.codedescription').webuiPopover({ closeable: false, trigger: 'hover', title: '', content: '', delay: { show: null, hide: 300} });
});