自动获取磁链接并自动离线下载
< Spätná väzba na 挊-随时开车
做了个btso的patch,能看懂代码的自己改一下,替换函数部分就是了,大概是550行附近
0: function (kw, cb) { GM_xmlhttpRequest({ method: "GET", url: "https://btspread.com/search/" + kw, onload: function (result) { let doc = common.parsetext(result.responseText); let data = []; let t = doc.querySelectorAll("div div .row"); let c = 0; if (t) { for (let elem of t) { if (c>0){ data.push({ "title": elem.children[0].title, "mag": "magnet:?xt=urn:btih:" + elem.children[0].href.replace(/.*\/hash\//,""), "size": elem.children[1].textContent, "src": elem.children[0].href, }); } c++; } } else { data.push({ "title": "没有找到磁链接", "mag": "", "size": "0", "src": result.finalUrl, }); } cb(result.finalUrl, data); }, onerror: function (e) { console.error(e); throw "search error"; } }); },
👍
Aby ste mohli pridať odpoveď, prihláste sa.
做了个btso的patch,能看懂代码的自己改一下,替换函数部分就是了,大概是550行附近