[
{
"bookSourceComment": "/*\n\t源网址后面不要加##,没做兼容\n\t\n\t发布页\n\thttps://qoqoqo.xyz/\n\thttps://永远的神.com/(Punycode ==> https://xn--5rwq3tukc919a.com/)\n*/",
"bookSourceGroup": "精选",
"bookSourceName": "🍺第一版主",
"bookSourceType": 0,
"bookSourceUrl": "https://永远的神.com/",
"bookUrlPattern": "https://www.(\\d+yydstxt|diyibanzhu)\\d+.com/\\d+/\\d+/",
"concurrentRate": "",
"customOrder": 0,
"enabled": true,
"enabledCookieJar": false,
"enabledExplore": true,
"exploreUrl": "<js>\n//状态\nnovelState = [\n\t{\ttitle: '全部', type: 0},\n\t{\ttitle: '连载', type: 1},\n\t{\ttitle: '完结', type: 2}\n]\n//分类\nnovelSort = [\n\t{\ttitle: ' 全部 ', type: 0},\n\t{\ttitle: '玄幻奇幻', type: 1},\n\t{\ttitle: '仙侠武侠', type: 2},\n\t{\ttitle: '都市言情', type: 3},\n\t{\ttitle: '穿越历史', type: 4},\n\t{\ttitle: '科幻灵异', type: 5},\n\t{\ttitle: ' 藏经阁 ', type: 6},\n\t{\ttitle: '其他类别', type: 7}\n]\n//排序\nnovelRank = [\n\t{ title: ' 更新 ', type: 'lastupdate'},\n\t{ title: '总人气', type: 'allvisit'},\n\t{ title: '月人气', type: 'monthvisit'},\n\t{ title: ' 字数 ', type: 'size'},\n\t{ title: ' 新书 ', type: 'postdate'}\n]\n\nlist = [];\nformatUrl = (sort, rank, state) => {\n\treturn `{{eval(String(source.loginUrl));_getUrl();}}shuku/${sort}-${rank}-${state}-{{page}}.html`;\n}\npushItem = (title, url, basis) => {\n\tlist.push({\n\t\ttitle: title,\n\t\turl: url,\n\t\tstyle: {\n\t\t\tlayout_flexGrow: 1,\n\t\t\tlayout_flexBasisPercent: basis\n\t\t}\n\t});\n}\n\nfor (stateItem of novelState) {\n\tpushItem(`🚫小说状态---${stateItem.title}🚫`, \"\", 1);\n\tfor (rankItem of novelRank) {\n\t\tnovelSort[0].title = \"📫\" + rankItem.title;\n\t\tfor (sortItem of novelSort) {\n\t\t\tpushItem(`${sortItem.title}`, formatUrl(sortItem.type, rankItem.type, stateItem.type), sortItem.type > 5 ? 0.45 : 0.25);\n\t\t}\n\t}\n}\nJSON.stringify(list);\n</js>",
"header": "<js>\n(() => {\n\ttry {\n\t\tdata = JSON.parse(source.getVariable())\n\t} catch (err) {\n\t\tdata = {}\n\t}\n\tsessionID = data.sessionID||\"\";\n\tif (!sessionID) {\n\t\tchars = \"abcdefghijklmnopqrstuvwxyz123456789\";\n\t\tcharsLength = chars.length\n\t\tfor (i = 0; i < 26; i++) {\n\t\t\tsessionID += chars.charAt(Math.floor(Math.random() * charsLength))\n\t\t}\n\t\tdata.sessionID = sessionID\n\t\tsource.setVariable(JSON.stringify(data))\n\t}\n\treturn JSON.stringify({\n\t\t\"cookie\": \"PHPSESSID=\" + sessionID,\n\t\t\"User-Agent\": \"Mozilla/5.0 (iPhone; CPU iPhone OS 13_3_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/13.0.5 Mobile/15E148 Snapchat/10.77.5.59 (like Safari/604.1)\"\n\t})\n})()\n</js>",
"jsLib": "",
"lastUpdateTime": 1695398253466,
"loginCheckJs": "//提取当前加载的域名\n_baseUrl = String(result.url()).replace(/(https?:\\/\\/.*?\\/).*/, \"$1\");\n//java.log(_baseUrl)\n//java.log(result.url())\n//java.log(baseUrl)\ntry {\n\t_data = JSON.parse(source.getVariable())\n} catch (err) {\n\t_data = {};\n}\n\t\nreSearch = false;//是否重新搜索\n//重定向\nif (_baseUrl.indexOf(baseUrl) == -1 && _data.url != _baseUrl) {\n\treSearch = true;\n\t_data.url = _baseUrl;\n\tsource.setVariable(JSON.stringify(_data));\n\tjava.log(\"重定向\");\n\tjava.key && java.initUrl();\n}\nurl = _data.url || _baseUrl;\nif (result.code() == 403) {\n\tlet _url = String(url + \",\" + JSON.stringify({\n\t\t\"method\": \"POST\",\n\t\t\"body\": \"action=1&v=1234\"\n\t}));\n\tlet checkres = java.ajax(_url);\n\tlet checkText = true;\n\tif (checkres == \"success\") checkText = checkres;\n\tjava.toast(\"自动验证:\" + checkText);\n\tresult = java.getStrResponse();\n\tjava.log(\"自动验证&重新获取:\" + checkText);\n} else if (reSearch && java.key) {\n\t//搜索时 重定向新网址需要重新获取搜索内容\n\tresult = java.getStrResponse();\n\tjava.log(\"重新搜索\");\n}\nresult",
"loginUi": "[\n\t{\n\t\tname: \" 获取源网址 \",\n\t\ttype: \"button\",\n\t\taction: \"_initSourceUrl()\"\n\t},\n\t{\n\t\tname: \" 初始化 \",\n\t\ttype: \"button\",\n\t\taction: \"_init()\"\n\t},\n\t{\n\t\tname: \" ◤ 更改源网址 ◥ \",\n\t\ttype: \"button\",\n\t\taction: \"\"\n\t},\n\t\n\t{\n\t\tname: \" 选项① \",\n\t\ttype: \"button\",\n\t\taction: \"_select(0)\"\n\t},\n\t{\n\t\tname: \" 选项② \",\n\t\ttype: \"button\",\n\t\taction: \"_select(1)\"\n\t},\n\t{\n\t\tname: \" 选项③ \",\n\t\ttype: \"button\",\n\t\taction: \"_select(2)\"\n\t},\n\t{\n\t\tname: \" 选项④ \",\n\t\ttype: \"button\",\n\t\taction: \"_select(3)\"\n\t},\n\t{\n\t\tname: \" 选项⑤ \",\n\t\ttype: \"button\",\n\t\taction: \"_select(4)\"\n\t},\n\t{\n\t\tname: \" 选项⑥ \",\n\t\ttype: \"button\",\n\t\taction: \"_select(5)\"\n\t},\n\t{\n\t\tname: \" 选项⑦ \",\n\t\ttype: \"button\",\n\t\taction: \"_select(6)\"\n\t},\n\t{\n\t\tname: \"取消选择\",\n\t\ttype: \"button\",\n\t\taction: \"_cancel()\"\n\t},\n\t{\n\t\tname: \"确定更改\",\n\t\ttype: \"button\",\n\t\taction: \"_confirm()\"\n\t}\n]",
"loginUrl": "let log = (text) => {\n\tif (text) {\n\t\tjava.toast(text);\n\t\tjava.log(text);\n\t}\n}\n\nlet _getData = () => {\n\ttry {\n\t\treturn JSON.parse(source.getVariable());\n\t} catch (err) {\n\t\treturn {};\n\t}\n}\n\nlet _setData = (obj) => {\n\tif (typeof obj == \"object\") {\n\t\tsource.setVariable(JSON.stringify(obj));\n\t}\n}\n\nlet _data = _getData();\n\nlet formatUrl = (string, replacement) => {\n\tlet replacementText = '/';\n\tif (replacement) replacementText += replacement;\n\treturn String(string).replace(/\\/?$/, replacementText);\n}\n\nlet ajax = (requestUrl) => {\n\tlet result = java.ajax(requestUrl);\n\t// 获取发布页通过<iframe>标签内嵌的发布页网址 https://xx/baidu.js\n\tlet _requestUrl = org.jsoup.Jsoup.parse(result).select(\"iframe\").attr(\"src\");\n\tif (result == '404') {\n\t\t// 发布页可直接访问,获取域名 https://xx/\n\t\tresult = java.ajax(requestUrl.replace(/(https?:\\/\\/.*?\\/).*/, \"$1\"));\n\t} else if (_requestUrl != \"\") {\n\t\t//发布页通过<iframe>标签内嵌网址\n\t\tresult = java.ajax(_requestUrl);\n\t}\n\treturn org.jsoup.Jsoup.parse(result).select(\".line a\");\n}\n\n//获取发布页列表\nlet _getPublishUrl = () => {\n\treturn [source.key, \"https://5s6s7s8s.com/\", \"https://qoqoqo.xyz/\", \"https://5m6m7m8m.com/\"];\n}\n\n//获取源网址列表\nlet _getSourceUrl = (urlList) => {\n\tlet logtext;\n\tlet total = 0;\n\tlet publishList = urlList ? urlList : _getPublishUrl();\n\tif (publishList.length > 0) {\n\t\tlet requestUrl = formatUrl(publishList[0], \"baidu.js\");\n\t\tlet eleObj = ajax(requestUrl);\n\n\t\tif (String(eleObj)) {\n\t\t\tfor (let _key in eleObj) {\n\t\t\t\tlet url = String(eleObj[_key].attr(\"href\"));\n\t\t\t\tif (url.trim() && _data.sourceUrl.indexOf(url) == -1) {\n\t\t\t\t\t_data.sourceUrl.push(url);\n\t\t\t\t\ttotal++;\n\t\t\t\t}\n\t\t\t}\n\t\t\tjava.log(`当前发布页${requestUrl}`);\n\t\t\tlogtext = `成功获取到${total}个源网址`;\n\t\t} else {\n\t\t\tjava.log(`当前发布页 ${requestUrl} 未获取到网址`);\n\t\t\tjava.log(`【删除当前发布页并重新获取】`);\n\t\t\treturn _getSourceUrl(publishList.slice(1));\n\t\t}\n\t} else {\n\t\tlogtext = `无可用发布页`;\n\t}\n\tlog(logtext);\n\t_setData(_data);\n}\n\n// 登录UI获取源网址\nlet _initSourceUrl = () => {\n\t_data.sourceUrl = [];\n\tlog(`【获取源网址中...】`);\n\t_getSourceUrl();\n}\n\n// 初始化\nlet _init = () => {\n\tlet obj1 = {\n\t\turl: \"\", //当前选中源网址\n\t};\n\tlet obj2 = {\n\t\tsourceUrl: [], //源网址列表\n\t\tsourceSelect: null, //\n\t\tloaded: true\n\t};\n\t_data = Object.assign({}, obj1, _data, obj2);\n\tlet separator = \",\\n \";\n\t_initSourceUrl();\n\tjava.log(_data.sourceUrl.join(separator));\n\tlog(`【选�