tablesorter&;Jquery使用INR货币对价格进行排序不起作用
我的问题涉及Jquery插件Tablesorter: 我对带有价格的列排序有问题,格式如下:₹135.35卢比,₹149.99卢比等 排序与价格列的排序效果很好,格式如下:$135.35美元,$149.99美元等 请检查一下 正如你所看到的,有点不对劲。有人能告诉我在这里该做什么吗 多谢各位 JS: `$j(document).ready(function(){ $j('.ssl-certi table').tablesorter(); });` `$j(文档).ready(函数(){ $j('.ssl certi table').tablesorter(); });` 我找到了我的答案: tablesorter.js在第903行有代码: ts.addParser({ id: "currency", is: function (s) { return /^[£$€?.]/.test(s); }, format: function (s) { return $.tablesorter.formatFloat(s.replace(new RegExp(/[£$€]/g), "")); }, type: "numeric" }); ts.addParser({ id:“货币”, is:功能{ 返回/^[£€?.]/.测试; },格式:函数{ return$.tablesorter.formatFloat(s.replace(新RegExp(/[£€]/g),“”); },类型:“数字” }); 将上述代码更改为 ts.addParser({ id: "currency", is: function (s) { return /^[£$€₹?.]/.test(s); }, format: function (s) { return $.tablesorter.formatFloat(s.replace(new RegExp(/[£$€₹]/g), "")); }, type: "numeric" }); ts.addParser({ id:“货币”, is:功能{ 返回/^[£€]₹?.]/.测试; },格式:函数{ return$.tablesorter.formatFloat(s.replace)(新的RegExp(/[£$€)₹]/g) (""),; },类型:“数字” });tablesorter&;Jquery使用INR货币对价格进行排序不起作用,jquery,Jquery,我的问题涉及Jquery插件Tablesorter: 我对带有价格的列排序有问题,格式如下:₹135.35卢比,₹149.99卢比等 排序与价格列的排序效果很好,格式如下:$135.35美元,$149.99美元等 请检查一下 正如你所看到的,有点不对劲。有人能告诉我在这里该做什么吗 多谢各位 JS: `$j(document).ready(function(){ $j('.ssl-certi table').tablesorter(); });` `$j(文档).ready(函数(){