diff --git a/js(origin)/bookinfo.js b/js(origin)/bookinfo.js index 4b3fc19..f0dcf8f 100644 --- a/js(origin)/bookinfo.js +++ b/js(origin)/bookinfo.js @@ -90,7 +90,7 @@ chrome.runtime.onMessage.addListener(function(message, sender,sendResponse) } mlt.t=temp.split('·')[0];//卷名 mlt.tc=temp.split('·')[1].split('共')[1].split('章')[0]-1+1;//总章数 - mlt.tw=temp.split('·')[1].split('共')[2].split('字')[0]-1+1;//总字数 + // mlt.tw=temp.split('·')[1].split('共')[2].split('字')[0]-1+1;//总字数 if(ci.children[i].children[1].children[te].className=="vip")mlt.vip=1;else mlt.vip=0;//是否为VIP卷 var t=ci.children[i].children[2]; mlt.l=getchatperlist(t,mlt.vip);//章节列表 @@ -98,13 +98,12 @@ chrome.runtime.onMessage.addListener(function(message, sender,sendResponse) else { var temp=ci.children[i].children[1].innerText.split('\n'); - temp=temp[temp.length-1]; - temp=temp.split(' '); - temp=[temp[temp.length-2],temp[temp.length-1]]; + temp = temp[4].split(' ') + temp = [temp[temp.length - 2], temp[temp.length - 1]] mlt.t=temp[0].split('·')[0];//卷名 mlt.tc=temp[0].split('共')[1].split('章')[0]-1+1;//总章数 if(temp[1].indexOf('免费')>-1)mlt.vip=0;else mlt.vip=1;//是否为VIP卷 - mlt.tw=temp[1].split('共')[1].split('字')[0]-1+1;//总字数 + // mlt.tw=temp[1].split('共')[1].split('字')[0]-1+1;//总字数 var t=ci.children[i].children[2]; mlt.l=getchatperlist(t,mlt.vip);//章节列表 } diff --git a/js(origin)/main.js b/js(origin)/main.js index 8e0db83..a7ce9de 100644 --- a/js(origin)/main.js +++ b/js(origin)/main.js @@ -441,6 +441,19 @@ function getfjinfo(ml,list) } return s; } +function caltw(ml) +{ + for(var i=0;i