您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Converts javascript:openWindow(...) to standard links that open in new tabs
// ==UserScript== // @name FCC Popup Fixer (Make All Links Open in Tabs) // @version 1.0 // @description Converts javascript:openWindow(...) to standard links that open in new tabs // @match *://apps.fcc.gov/* // @grant none // @namespace https://greasyfork.org/users/1484279 // ==/UserScript== (function () { 'use strict'; const fixLinks = () => { document.querySelectorAll('a[href^="javascript:openWindow("]').forEach(a => { const match = a.getAttribute('href').match(/openWindow\('([^']+)'\)/); if (match && match[1]) { const realUrl = new URL(match[1], location.origin).href; a.setAttribute('href', realUrl); a.setAttribute('target', '_blank'); a.removeAttribute('onclick'); // in case there's an extra click handler } }); }; // Run once after DOM is ready if (document.readyState === 'loading') { document.addEventListener('DOMContentLoaded', fixLinks); } else { fixLinks(); } })();