jQuery Tablesorter分页器插件无法在Edge模式下与IE11一起正常使用 [英] JQuery tablesorter pager plugin doesn't work properly with IE11 in Edge mode

查看:172
本文介绍了jQuery Tablesorter分页器插件无法在Edge模式下与IE11一起正常使用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如果您将Tablesorter Jquery插件与分页器一起使用,则在表上添加将不会显示任何数据.数据在那里,但是它是隐藏的.

If you are using the Tablesorter Jquery plugin with the pager add on the table will not display any of the data. The data is there but it is hidden.

我怀疑插件的浏览器功能检测方法无法处理IE11.

I suspect the browser feature detection method of the plugin can't handle IE11.

还有其他人碰到这个吗?

Anyone else run into this?

推荐答案

似乎IE11的userAgent出现问题. 一种解决方法是像这样更改clearTableBody函数(在jquery.tablesorter-2.0.3.js中工作):

It seems that IE11 have a problem with his userAgent. A turnaround is to change clearTableBody function (working in jquery.tablesorter-2.0.3.js) like this :

this.clearTableBody = function (table) {
    //if ($.browser.msie) {
        function empty() {
            while (this.firstChild) this.removeChild(this.firstChild);
        }
        empty.apply(table.tBodies[0]);
    //} else {
    //    table.tBodies[0].innerHTML = "";
    //}
};

这篇关于jQuery Tablesorter分页器插件无法在Edge模式下与IE11一起正常使用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆