您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Discuz论坛链接默认新链接打开,支持autopager和Super_preloader等
当前为
// ==UserScript== // @name Open Discuz Link in new tab // @description Discuz论坛链接默认新链接打开,支持autopager和Super_preloader等 // @include http://*/forum-*-* // @include http://*/forum-*-*.html // @include http://*/showforum-*.html // @include http://*/forum.php?mod=forumdisplay* // @include http://*/forum/viewforum.php?f=* // @include http://*/forum/search.php?* // @include https://*/forum-*-* // @include https://*/forum-*-*.html // @include https://*/showforum-*.html // @include https://*/forum.php?mod=forumdisplay* // @include https://*/forum/viewforum.php?f=* // @include https://*/forum/search.php?* // @namespace Lkytal // @require http://code.jquery.com/jquery-2.1.0.min.js // @version 1.2.6 // @icon http://lkytal.qiniudn.com/ic.ico // @grant unsafeWindow // @homepageURL https://greasyfork.org/scripts/343-open-discuz-link-in-new-tab/ // ==/UserScript== if (window != window.top || window.document.title == "") { return; } var x = document.getElementById('atarget'); if( x ) { //x.click(); unsafeWindow.setatarget(1); } else { $('#threadlist').filter('tbody a').attr("target", "_blank").removeAttr("onClick"); /*document.addEventListener('DOMNodeInserted',function() { LinkNew(); } ); observer = new window.MutationObserver(LinkNew); observer.observe(document.body, {childList: true, subtree: true});*/ }