找到函数:
function getElementText(config, node) {
var text = "";
if (!node) return "";
if (!config.supportsTextContent) config.supportsTextContent = node.textContent || false;
if (config.textExtraction == "simple") {
if (config.supportsTextContent) {
text = node.textContent;
} else {
if (node.childNodes[0] && node.childNodes[0].hasChildNodes()) {
text = node.childNodes[0].innerHTML;
} else {
text = node.innerHTML;
}
}
} else {
if (typeof(config.textExtraction) == "function") {
text = config.textExtraction(node);
} else {
text = $(node).text();
}
}
return text;
}
把上邊的function改成下邊的即可:
function getElementText(config, node) {
var text = "";
if (!node) return "";
if (!config.supportsTextContent) config.supportsTextContent = node.textContent || false;
if (config.textExtraction == "simple") {
if (config.supportsTextContent) {
text = node.textContent;
} else {
if (node.childNodes[0] && node.childNodes[0].hasChildNodes()) {
text = node.childNodes[0].innerHTML;
} else {
text = node.innerHTML;
}
}
} else {
if (typeof(config.textExtraction) == "function") {
text = config.textExtraction(node);
} else {
text = $(node).text();
}
}
return (text.replace(/,/g,''));
}

最新文章

  1. 使用ab对nginx进行压力测试
  2. 数据库SQL优化大总结之 百万级数据库优化方案
  3. 学习zepto.js(对象方法)[5]
  4. flume整合kafka
  5. group_concat函数使用
  6. SQL Server 用户名密码查看
  7. HTML-meta
  8. hnu Counting ones 统计1-n 二进制中1的个数
  9. linux下ftp常用命令
  10. 高性能javascript及页面注意事项
  11. PHP经验集锦
  12. 【转】cocos2d-x游戏开发(十四)用shader使图片背景透明
  13. Java通过JDBC链接数据库,数据库中wen
  14. [置顶] 【J2SE 】1136 容器之旅
  15. PHP MYSQL数据字典
  16. 101个linq例子
  17. How Django works?
  18. 如何访问pcie整个4k的配置空间
  19. 安卓开发笔记(二十四):手把手教你一步步集成腾讯X5内核(Tencent TBS X5)
  20. 通过JS生成由字母与数字组合的随机字符串

热门文章

  1. CSS样式之语法
  2. ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
  3. mORMot 数据库操作
  4. SQl server master
  5. @Html.Partials 加载分布视图传参数
  6. Highcharts图形报表的简单使用
  7. 2007Hanoi双塔问题
  8. mvc-servlet---servletContext与servletConfig2
  9. Cocos2d-x Application Wizard for Visual Studio User Guide
  10. day8---多线程socket 编程,tcp粘包处理