您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
将丑陋的php链接转换为HTML链接
当前为
// ==UserScript== // @name MCBBS PHP转HTML 链接 (支持吾爱破解) // @namespace https://github.com/404.html // @version 0.4.4-fix3 // @license AGPLv3 or later // @description 将丑陋的php链接转换为HTML链接 // @author axototl // @match *://www.mcbbs.net/* // @match *://www.52pojie.cn/* // @icon https://www.mcbbs.net/favicon.ico // @grant GM_getValue // @grant GM_setValue // @grant GM_registerMenuCommand // @grant GM_unregisterMenuCommand // @run-at document-start // ==/UserScript== const tips = ["×定位到原贴(点击以启用)", "√定位到原贴(点击以禁用)"]; let config = { get sethash() { return GM_getValue("sethash", true); }, set sethash(val) { GM_setValue("sethash", val); } }; (function() { 'use strict'; var srid = GM_registerMenuCommand(tips[config.sethash|0], changer); function changer(){ config.sethash = !config.sethash; GM_unregisterMenuCommand(srid); srid = GM_registerMenuCommand(tips[config.sethash|0], changer); } var uri = location.href; var url = new URL(uri); if (url.searchParams.get("goto") == "lastpost") return; if (url.searchParams.get("mod") == "viewthread") { let tid = url.searchParams.get("tid"); let page = url.searchParams.get("page"); if (!page) page = "1"; history.replaceState(null, "", "https://"+ location.host + "/thread-"+ tid +"-"+ page +"-1.html"+ (config.sethash ? location.hash : "")); } else if (uri.indexOf("link_redirect") > -1) // skip alert. location.assign(url.searchParams.get("target")); })();
QingJ © 2025
镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址