diff --git a/.github/ISSUE_TEMPLATE/03-autoPageRequest.yml b/.github/ISSUE_TEMPLATE/03-autoPageRequest.yml index ec1f4a675..e27a94a98 100644 --- a/.github/ISSUE_TEMPLATE/03-autoPageRequest.yml +++ b/.github/ISSUE_TEMPLATE/03-autoPageRequest.yml @@ -14,12 +14,13 @@ body: > [!IMPORTANT] > ### \# 申请必读: > 1. 请先确认 **`不是动态加载内容`** 的网站(**鼠标指向页码,左下角不显示链接即代表是动态加载**),这类网站无法制作规则。 - > 2. 如 **`需要登录`** 才能看到内容,请先联系我**私下告诉账号**,否则我**无法凭空制作**翻页规则(网课类不会添加支持)。 - > 3. 请直接提供 **`具体页面的网页地址 URL`** (特别是一些**页面很多的网站**),尽量减少我的工作量,否则可能拒绝申请。 + > 2. 如 **`需要登录`** 才能看到内容(无论注册有多简单),请**告诉我账号**,否则我**无法凭空制作**翻页规则(网课类不会支持)。 + > 3. 请提供希望添加支持的 **`可翻页(含有页码)的具体网页地址`** 以供我编写规则(特别是**页面很多的网站**),尽量减少我的工作量,否则可能拒绝。 + > 4. 对于 **`正版小说/漫画`** 网站,因为**反爬防盗**的原因也会导致无法制作规则(该脚本本质上也是爬虫,虽然只爬取下一页,但也会被阻碍)。 + > 5. 对于 **`没有 HTTPS`** 的网站(这种网站目前全网占比极少,且大都是一些老旧网站),是不考虑添加支持的。 + > 6. 如果你要申请对 `某个博客/论坛系统` 添加支持(即通用规则,所有使用这个博客/论坛系统的网站都会支持),那么需要提供 `官方博客/论坛地址` 及 其他**几个使用该博客/论坛系统的网站地址**,用于对比、验证,才能写出通用规则。 - > - 另外,对于**正版小说/漫画**网站,因为反爬防盗的原因也会导致无法制作规则(该脚本本质上也是爬虫,虽然只爬取下一页)。 - > - 另外,对于**没有 HTTPS** 的网站(这种网站目前全网占比极少,且大都是一些老旧网站),是不考虑添加支持。 - > - 另外,如果你要申请脚本对 `某个博客/论坛系统` 添加支持(即通用规则,所有使用这个博客/论坛系统的网站都会支持),那么需要提供 `官方博客/论坛地址` 及 其他**几个使用该博客/论坛系统的网站地址**,用于对比、验证,才能写出通用规则。 + > - 对于需要登录才能看的网页,哪怕注册再简单我也不会去主动注册,你可以用一些 **`阅后即焚`** 的网站来告诉我你的账号密码(毕竟 Github 没有私信功能,你可以提前把密码改成别的,我用完了你再改回去),也可以用各种 **`在线临时邮箱`** 网站随便申请个账号给我用,但不管如何你必须提供一个账号给我才能编写规则,这是基本原则。 **** - type: input id: websitename diff --git a/Autopage.user.js b/Autopage.user.js index 5473c4b72..8d4913b67 100644 --- a/Autopage.user.js +++ b/Autopage.user.js @@ -1,37 +1,36 @@ // ==UserScript== -// @name 自动无缝翻页 +// @name AutoPager // @name:zh-CN 自动无缝翻页 // @name:zh-TW 自動無縫翻頁 -// @name:en AutoPager -// @version 6.6.32 +// @name:ru Автостраничник +// @version 6.6.75 // @author X.I.U -// @description ⭐无缝加载 下一页内容 至网页底部(类似瀑布流,无限滚动,无需手动点击下一页)⭐,目前支持:【所有「Discuz!、Flarum、phpBB、MyBB、Xiuno、XenForo、NexusPHP...」论坛】【百度、谷歌(Google)、必应(Bing)、搜狗、微信、360、Yahoo、Yandex 等搜索引擎...】、贴吧、豆瓣、知乎、NGA、V2EX、起点中文、千图网、千库网、Pixabay、Pixiv、3DM、游侠网、游民星空、NexusMods、Steam 创意工坊、CS.RIN.RU、RuTracker、BT之家、萌番组、动漫花园、樱花动漫、爱恋动漫、AGE 动漫、Nyaa、SrkBT、RARBG、SubHD、423Down、不死鸟、扩展迷、小众软件、【动漫狂、动漫屋、漫画猫、漫画屋、漫画 DB、HiComic、Mangabz、Xmanhua 等漫画网站...】、PubMed、Z-Library、GreasyFork、Github、StackOverflow(以上仅一小部分常见网站,更多的写不下了... +// @description ⭐Append the next page content to the bottom seamlessly (like a waterfall, Unlimited scrolling, no need to manually click on the next page) ⭐, support various forums, social networking, games, comics, novels, academics, search engines (Google, Bing, Yahoo...) and other websites~ +// @description:zh-CN ⭐无缝加载 下一页内容 至网页底部(类似瀑布流,无限滚动,无需手动点击下一页)⭐,支持各论坛、社交、游戏、漫画、小说、学术、搜索引擎(Google、Bing、Yahoo...) 等网站~ // @description:zh-TW ⭐無縫加載 下一頁內容 至網頁底部(類似瀑布流,无限滚动,無需手働點擊下一頁)⭐,支持各論壇、社交、遊戲、漫畫、小說、學術、搜索引擎(Google、Bing、Yahoo...) 等網站~ -// @description:en Append the next page content to the bottom seamlessly (like a waterfall, Unlimited scrolling, no need to manually click on the next page)~ +// @description:ru ⭐Плавно добавляет содержимое следующей страницы к нижней части (как водопад, неограниченная прокрутка, не нужно вручную нажимать на следующую страницу) ⭐, поддерживает различные форумы, соцсети, игры, комиксы, романы, научные статьи, поисковики (Google, Bing, Yahoo...) и другие сайты~ // @match *://*/* // @connect userscript.xiu2.xyz -// @connect userscript.xiu2.us.kg // @connect userscript.h233.eu.org // @connect bitbucket.org +// @connect jsd.onmicrosoft.cn +// @connect wget.la +// @connect ghfast.top +// @connect ghproxy.cfd +// @connect raw.dgithub.xyz +// @connect ghproxy.net +// @connect cdn.jsdmirror.com // @connect js.cdn.haah.net -// @connect jsdelivr.b-cdn.net -// @connect raw.ixnic.net -// @connect raw.nuaa.cf -// @connect raw.yzuu.cf // @connect raw.kkgithub.com -// @connect raw.incept.pw -// @connect gitdl.cn -// @connect ghproxy.cc -// @connect ghproxy.net -// @connect ghp.ci -// @connect github.moeyy.xyz -// @connect jsd.onmicrosoft.cn -// @connect cdn.jsdelivr.us // @connect gcore.jsdelivr.net // @connect fastly.jsdelivr.net -// @connect cdn.jsdmirror.com // @connect jsd.proxy.aks.moe // @connect jsdelivr.pai233.top +// @connect gh-proxy.org +// @connect hk.gh-proxy.org +// @connect hub.glowp.xyz +// @connect g.blfrp.cn +// @connect gh.catmak.name // @connect www.xuexiniu.com // @connect bbs.xuexiniu.com // @connect weili.ooopic.com @@ -91,42 +90,30 @@ (function() { 'use strict'; - const urlArr = [ // 外置翻页规则更新地址分流,以确保更新成功率(记得 connect) - 'https://userscript.h233.eu.org/other/Autopage/rules.json', - 'https://userscript.xiu2.us.kg/other/Autopage/rules.json', - 'https://bitbucket.org/xiu2/userscript/raw/master/other/Autopage/rules.json', - 'https://raw.kkgithub.com/XIU2/UserScript/master/other/Autopage/rules.json', - 'https://gitdl.cn/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', - //'https://raw.incept.pw/XIU2/UserScript/master/other/Autopage/rules.json', - 'https://raw.ixnic.net/XIU2/UserScript/master/other/Autopage/rules.json', - 'https://raw.nuaa.cf/XIU2/UserScript/master/other/Autopage/rules.json', - 'https://raw.yzuu.cf/XIU2/UserScript/master/other/Autopage/rules.json', - 'https://ghproxy.cc/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', - 'https://ghproxy.net/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', - 'https://ghp.ci/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', - 'https://github.moeyy.xyz/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', - //'https://cdn.jsdelivr.us/gh/XIU2/UserScript/other/Autopage/rules.json', - 'https://jsd.onmicrosoft.cn/gh/XIU2/UserScript/other/Autopage/rules.json', + let urlArr = [ // 外置翻页规则更新地址分流,以确保更新成功率(记得 connect) + 'https://cdn.jsdmirror.com/gh/XIU2/UserScript/other/Autopage/rules.json', + //'https://js.cdn.haah.net/gh/XIU2/UserScript/other/Autopage/rules.json', // 证书过期 + //'https://raw.kkgithub.com/XIU2/UserScript/master/other/Autopage/rules.json', // 超时 //'https://gcore.jsdelivr.net/gh/XIU2/UserScript/other/Autopage/rules.json', 'https://fastly.jsdelivr.net/gh/XIU2/UserScript/other/Autopage/rules.json', - 'https://jsdelivr.b-cdn.net/gh/XIU2/UserScript/other/Autopage/rules.json', - 'https://cdn.jsdmirror.com/gh/XIU2/UserScript/other/Autopage/rules.json', - 'https://jsd.proxy.aks.moe/gh/XIU2/UserScript/other/Autopage/rules.json', - 'https://jsdelivr.pai233.top/gh/XIU2/UserScript/other/Autopage/rules.json', - 'https://js.cdn.haah.net/gh/XIU2/UserScript/other/Autopage/rules.json', - ], urlArr2 = [ + //'https://jsd.proxy.aks.moe/gh/XIU2/UserScript/other/Autopage/rules.json', + //'https://jsdelivr.pai233.top/gh/XIU2/UserScript/other/Autopage/rules.json', + 'https://hub.glowp.xyz/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', + 'https://g.blfrp.cn/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', + 'https://gh.catmak.name/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', + 'https://gh-proxy.org/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', + 'https://hk.gh-proxy.org/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', + ] + const urlArr2 = [ 'https://userscript.h233.eu.org/other/Autopage/rules.json', - 'https://userscript.xiu2.us.kg/other/Autopage/rules.json', 'https://userscript.xiu2.xyz/other/Autopage/rules.json', 'https://bitbucket.org/xiu2/userscript/raw/master/other/Autopage/rules.json', - 'https://raw.kkgithub.com/XIU2/UserScript/master/other/Autopage/rules.json', - 'https://gitdl.cn/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', - 'https://raw.ixnic.net/XIU2/UserScript/master/other/Autopage/rules.json', - 'https://raw.nuaa.cf/XIU2/UserScript/master/other/Autopage/rules.json', - 'https://raw.yzuu.cf/XIU2/UserScript/master/other/Autopage/rules.json', - 'https://ghproxy.net/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', - 'https://ghp.ci/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', - 'https://github.moeyy.xyz/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', + 'https://jsd.onmicrosoft.cn/gh/XIU2/UserScript/other/Autopage/rules.json', + 'https://wget.la/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', + 'https://ghfast.top/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', + //'https://ghproxy.cfd/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', // 超时 + //'https://raw.dgithub.xyz/XIU2/UserScript/master/other/Autopage/rules.json', // 证书挂了 + //'https://ghproxy.net/https://raw.githubusercontent.com/XIU2/UserScript/master/other/Autopage/rules.json', // 挂了 ], loadMoreExclude1 = ['.smzdm.com','stackoverflow.com'], loadMoreExclude2 = ['.steampowered.com','.zcool.com.cn']; @@ -137,9 +124,10 @@ ['menu_page_number', '显示当前页码及点击暂停翻页', '显示当前页码及点击暂停翻页', true], ['menu_pause_page', '左键双击网页空白处暂停翻页', '左键双击网页空白处暂停翻页', false], ['menu_history', '添加历史记录+修改地址/标题', '添加历史记录+修改地址/标题', true], - ['menu_rules', '更新外置翻页规则 (每天自动)', '更新外置翻页规则 (每天自动)', {}], + ['menu_rules', '更新外置翻页规则 (定期自动)', '更新外置翻页规则 (定期自动)', {}], ['menu_customRules', '自定义翻页规则', '自定义翻页规则', {}] ], menuId = [], webType = 0, curSite = {SiteTypeID: 0}, DBSite, DBSite2, DBSiteNow, pausePage = true, pageNum = {now: 1, _now: 1}, urlC = false, nowLocation = '', lp = location.pathname, scriptHandler; + urlArr.push(...urlArr2); // 合并数组 window.autoPage = {lp: ()=>location.pathname, indexOF: indexOF, isMobile: isMobile, isUrlC: isUrlC, isPager: isPager, isTitle: isTitle, blank: forceTarget, getAll: getAll, getOne: getOne, getAllXpath: getAllXpath, getXpath: getXpath, getAllCSS: getAllCSS, getCSS: getCSS, getNextE: getNextE, getNextEP: getNextEP, getNextSP: getNextSP, getNextEPN: getNextEPN, getNextUPN: getNextUPN, getNextUP: getNextUP, getNextF: getNextF, getSearch: getSearch, getCookie: getCookie, insStyle: insStyle, insScript: insScript, cleanuEvent: cleanuEvent, src_bF: src_bF, xs_bF: xs_bF, pageNumIncrement: pageNumIncrement} if (typeof GM_info != 'undefined') {scriptHandler = GM_info.scriptHandler;} else if (typeof GM != 'undefined' && typeof GM.info != 'undefined') {scriptHandler = GM.info.scriptHandler;} else {scriptHandler = '';} for (let i=0;i git 托管系统`); return 15; - } else if (loadMoreExclude(loadMoreExclude1) && getAllCSS('.load-more, .load_more, .loadmore, #load-more, #load_more, #loadmore, [id^="loadmore"], .show-more, .show_more, .ajax-more').length === 1) { + } else if (loadMoreExclude(loadMoreExclude1) && getAllCSS('.load-more, .load_more, .loadmore, #load-more, #load_more, #loadmore, [id^="loadmore"], .show-more:not([data-gps-track]), .show_more, .ajax-more').length === 1) { console.info(`[自动无缝翻页] - 部分自带 自动无缝翻页 的网站 1`); return 8; } else if (loadMoreExclude(loadMoreExclude2) && getAllXpath('//*[self::a or self::span or self::button or self::div][text()="加载更多"][not(@href) or @href="#" or starts-with(@href, "javascript")]').length === 1) { @@ -322,17 +317,19 @@ } else if (getAllCSS('.entry-content .single-content img').length > 3) { DBSite.wp_article_post.pager.pageE = '.entry-content .single-content' } else if (getAllCSS('.entry-content').length == 1) { - DBSite.wp_article_post.pager.pageE = '.entry-content>*:not(.wbp-cbm):not(.page-links):not(.post-links):not(.article-paging):not(.entry-pagination):not(.pagination):not(.fenye):not(.open-message):not(#social):not(.article-social):not(.single-cat-tag):not(.single-meta):not(#fontsize):not(.clear):not(.tg-m):not(.tg-site):not(footer)' + DBSite.wp_article_post.pager.pageE = '.entry-content>*:not(.wbp-cbm):not(.page-links):not(.post-links):not(.article-paging):not(.entry-pagination):not(.pagination):not(.fenye):not(.open-message):not(#social):not(.article-social):not(.single-cat-tag):not(.single-meta):not(#fontsize):not(.clear):not(.tg-m):not(.tg-site):not(footer):not([class*=pagination])' } else if (getAllCSS('.article-content').length == 1) { - DBSite.wp_article_post.pager.pageE = '.article-content>*:not(.page-links):not(.post-links):not(.article-paging):not(.entry-pagination):not(.pagination):not(.fenye):not(.open-message):not(#social):not(.article-social):not(.single-cat-tag):not(.single-meta):not(#fontsize):not(.clear):not(.tg-m):not(.tg-site):not(footer)' + DBSite.wp_article_post.pager.pageE = '.article-content>*:not(.page-links):not(.post-links):not(.article-paging):not(.entry-pagination):not(.pagination):not(.fenye):not(.open-message):not(#social):not(.article-social):not(.single-cat-tag):not(.single-meta):not(#fontsize):not(.clear):not(.tg-m):not(.tg-site):not(footer):not([class*=pagination])' } else if (getAllCSS('article').length == 1) { - DBSite.wp_article_post.pager.pageE = 'article>*:not(.page-links):not(.post-links):not(.article-paging):not(.entry-pagination):not(.pagination):not(.fenye):not(.open-message):not(#social):not(.article-social):not(.single-cat-tag):not(.single-meta):not(#fontsize):not(.clear):not(.tg-m):not(.tg-site):not(footer)' + DBSite.wp_article_post.pager.pageE = 'article>*:not(.page-links):not(.post-links):not(.article-paging):not(.entry-pagination):not(.pagination):not(.fenye):not(.open-message):not(#social):not(.article-social):not(.single-cat-tag):not(.single-meta):not(#fontsize):not(.clear):not(.tg-m):not(.tg-site):not(footer):not([class*=pagination])' } if (DBSite.wp_article_post.pager.pageE != undefined) console.info(`[自动无缝翻页] - 部分使用 WordPress 的网站 - 文章内`); return 11; } - if (getCSS('a.next, a.next-page')) { + if (getCSS('a.next.page-numbers, a.next-page.page-numbers')) { + DBSite.wp_article.pager.nextL = 'a.next.page-numbers, a.next-page.page-numbers' + } else if (getCSS('a.next, a.next-page')) { DBSite.wp_article.pager.nextL = 'a.next, a.next-page' } else if (getCSS('a[rel="next" i], a[aria-label="next" i], a[aria-label="下一个"].page-link, a[aria-label="Next Page" i], a[aria-label="下一页"], a[rel="下一页"], a[title="下一页"], a[aria-label="下一頁"], a[rel="下一頁"], a[title="下一頁"]')) { DBSite.wp_article.pager.nextL = 'a[rel="next" i], a[aria-label="next" i], a[aria-label="下一个"].page-link, a[aria-label="Next Page" i], a[aria-label="下一页"], a[rel="下一页"], a[title="下一页"], a[aria-label="下一頁"], a[rel="下一頁"], a[title="下一頁"]' @@ -373,7 +370,7 @@ if (getAllCSS('.posts-wrapper.row>div>article').length > 3) { DBSite.wp_article.pager.pageE = '.posts-wrapper.row>div' } else if (getAllXpath('//div[contains(@class,"row")]/div/article').length > 3) { - DBSite.wp_article.pager.pageE = '//div[contains(@class,"row")]/div/article/parent::div' + DBSite.wp_article.pager.pageE = '//div[contains(@class,"row")]/div/article' } else if (getAllCSS('article[id^="post-"]').length > 3) { DBSite.wp_article.pager.pageE = 'article[id^="post-"]' } else if (getAllCSS('article[class]').length > 3) { @@ -400,11 +397,11 @@ } else if (getCSS('.stui-page, .stui-page__item, #long-page, .myui-page, .myui-page__item')) { console.info(`[自动无缝翻页] - 部分影视网站`); return 300; - } else if (getCSS('#page') && getCSS('.module-items')) { + } else if (getCSS('#page') && getCSS('.module-items,a.module-poster-item')) { console.info(`[自动无缝翻页] - 部分影视网站 2`); return 301; } else if (getCSS('.ArticleImageBox, .PictureList') && getCSS('.article_page') && getXpath('//div[contains(@class,"article_page")]//a[text()="下一页"]')) { - console.info(`[自动无缝翻页] - 部分美女图站 - 手机版`); return 302; + console.info(`[自动无缝翻页] - 部分美图网站 - 手机版`); return 302; } else if (getCSS('meta[content^=SearXNG i], link[href*=SearXNG i], script[src*=SearXNG i]')) { console.info(`[自动无缝翻页] - 元搜索引擎`); return 303; @@ -414,8 +411,8 @@ console.info(`[自动无缝翻页] - <笔趣阁 1 - 手机版> 模板的小说网站`); return 201; } else if (getCSS('#txt, .txt') && getCSS('#pb_next, .url_next') && getCSS('.chapter-control, .chapter-page-btn')) { console.info(`[自动无缝翻页] - <笔趣阁 2> 模板的小说网站`); return 202; - } else if ((getCSS('meta[name="description" i][content*="小说"], meta[name="description" i][content*="章节"], meta[name="description" i][content*="阅读"], meta[name="keywords" i][content*="笔趣"]') || location.hostname.indexOf('biqu')!=-1 || document.title.match(/笔趣阁|小说|章/)!=null) && getXpath('//a[contains(text(), "下一章") or contains(text(), "下一页") or contains(text(), "下一节")]')) { - let biquge3_pageE= ['[id="chapter_content" i]','[class~="chapter_content" i]','[id="chaptercontent" i]','[class~="chaptercontent" i]','[id="booktext" i]','[class~="booktext" i]','[id="txtcontent" i]','[class~="txtcontent" i]','[id="textcontent" i]','[class~="textcontent" i]','[id="read-content" i]','[class~="read-content" i]','[id="txtnav" i]','[class~="txtnav" i]','[id="txt" i][class~="txt" i]','[id="contents" i]','[class~="contents" i]','[id="content" i]','[class~="content" i]'] + } else if ((getCSS('meta[name="description" i][content*="小说"], meta[name="description" i][content*="章节"], meta[name="description" i][content*="阅读"], meta[name="description" i][content*="小說"], meta[name="description" i][content*="章節"], meta[name="description" i][content*="閲讀"], meta[name="keywords" i][content*="笔趣"]') || location.hostname.indexOf('biqu')!=-1 || document.title.match(/笔趣阁|书库|小说|小說|章/)!=null) && getXpath('//a[contains(text(), "下一章") or contains(text(), "下一页") or contains(text(), "下一节")][not(starts-with(@href,"javascript:"))]')) { + let biquge3_pageE= ['[id="chapter_content" i]','[class~="chapter_content" i]','[id="chaptercontent" i]','[class~="chaptercontent" i]','[class~="read_chapterdetail" i]','[id="booktext" i]','[class~="booktext" i]','[id="txtcontent" i]','[class~="txtcontent" i]','[id="textcontent" i]','[class~="textcontent" i]','[id="read-content" i]','[class~="read-content" i]','[id="txtnav" i]','[class~="txtnav" i]','[id="txt" i][class~="txt" i]','[id="contents" i]','[class~="contents" i]','[id="content" i]','[class~="content" i]','[id="acontent" i]','[class~="acontent" i]','[id="contentbox" i]','.container>.con'] for(let biquge3_pageE_ of biquge3_pageE) {if (getAllCSS(biquge3_pageE_).length === 1) {DBSite.biquge3.pager.pageE = biquge3_pageE_;DBSite.biquge3.pager.insertP = [biquge3_pageE_,6];DBSite.biquge3.style = biquge3_pageE_+'>.readinline, ' + DBSite.biquge3.style;break;}} if (DBSite.biquge3.pager.pageE != undefined) {console.info(`[自动无缝翻页] - <笔趣阁 3> 模板的小说网站`); return 203;} } @@ -465,7 +462,7 @@ curSite = DBSite.yingshi; break; case 301: // < 部分影视网站 2 > curSite = DBSite.yingshi2; break; - case 302: // < 部分美女图站 - 手机版 > + case 302: // < 部分美图网站 - 手机版 > curSite = DBSite.meinvtu_m; break; case 303: // < SearXNG 元搜索引擎 > document.cookie='infinite_scroll=1; expires=Thu, 18 Dec 2031 12:00:00 GMT; path=/'; @@ -479,7 +476,7 @@ /* inherits: 继承标识,仅用于自定义规则,用于增删改某个外置规则的部分规则时,可使用该标识来省略不需要修改的规则,只写有变化的规则 - url: 匹配到该域名后要执行的函数/正则(一般用于根据 URL 分配相应翻页规则) + url: 匹配到该域名后要执行的函数/正则(一般用于根据 URL 分配相应翻页规则,url 规则中可通过操作 rule 这个对象变量来修改当前网页实际应用的规则) urlC: 对于使用 pjax 技术的网站,需要监听 URL 变化来重新判断翻页规则(需要放在 url: 中,自定义规则的话需要使用 fun.isUrlC()) noReferer: 获取下一页内容时,不携带 Referer(部分网站携带与不携带可能不一样) @@ -504,12 +501,12 @@ pager: { nextText: 按钮文本,当按钮文本 = 该文本时,才会点击按钮加载下一页(避免一瞬间加载太多次下一页,下同) nextTextOf: 按钮文本的一部分,当按钮文本包含该文本时,才会点击按钮加载下一页 nextHTML: 按钮内元素,当按钮内元素 = 该元素内容时,才会点击按钮加载下一页 - interval: 点击间隔时间,对于没有按钮文字变化的按钮,可以手动指定间隔时间(单位 ms,默认 500,当指定上面三个时,会忽略 interval) + interval: 点击间隔时间,对于没有按钮文字变化的按钮,可以手动指定间隔时间(省略后默认 500ms,当指定上面三个时,会忽略 interval) isHidden: 只有下一页按钮可见时(没有被隐藏),才会点击 3 = 依靠 [基准元素] 与 [浏览器可视区域底部] 之间的距离缩小来触发翻页(适用于:主体元素下方内容太多 且 高度不固定时) - scrollE: 作为基准线的元素(一般为底部页码元素),和 replaceE 一样的话可以省略 - scrollD: 基准元素 - 可视区域底部 + scrollE: 作为基准线的元素(一般为底部页码元素),省略后默认等同 replaceE(如果这个也未指定则改用 nextL) + scrollD: 当 [基准元素] 与 [可视区域底部] 之间的距离 等于或小于该值时,将触发翻页,省略后默认 2000 4 = 动态加载类网站(适用于:简单的动态加载内容网站) insertE: 用来插入元素的函数 @@ -519,7 +516,7 @@ pager: { iframe: 这个必须加到 pager{} 外面(这样才会在该域名的 iframe 框架下运行脚本) 6 = 通过 iframe 获取下一页动态加载内容插入本页,只有一个娃(适用于:部分动态加载内容的网站,与上面不同的是,该模式适合简单的网页,没有复杂事件什么的) - loadTime: 预留的网页加载时间,确保网页内容加载完成 + loadTime: 预留的网页加载时间,确保网页内容加载完成(省略后默认为 300ms) nextL: 下一页链接所在元素 pageE: 要从下一页获取的元素 @@ -537,7 +534,7 @@ pager: { 注意:如 pageE 中选择了多类元素,则不能省略 insertP(比如包含 `,` 与 `|` 符号),除非另外的选择器是