您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Greasy Fork is available in English.
If youtube is in the new 2017 YouTube Material Redesign, automatically restore classic view
当前为
// ==UserScript== // @name Youtube - Restore Classic // @version 1.0.0 // @description If youtube is in the new 2017 YouTube Material Redesign, automatically restore classic view // @author Cpt_mathix // @match https://www.youtube.com // @include https://www.youtube.com/* // @license GPL version 2 or any later version; http://www.gnu.org/licenses/gpl-2.0.txt // @namespace http://greasyfork.icu/users/16080 // @run-at document-start // @grant none // @noframes // ==/UserScript== (function() { replaceCookie("PREF"); function replaceCookie(name) { var match = document.cookie.match(RegExp('(?:^|;\\s*)' + name + '=([^;]*)')); if (match ? match[1] && match[1].search(/f6=(a|b)/) === -1 : null) { if (match[1].search(/f6=(a|b)/) === -1) { document.cookie = "PREF=" + match[1] + "&f6=a" + ";path=/;domain=.youtube.com"; } else if (match[1].search(/f6=\d/) !== -1) { document.cookie = "PREF=" + match[1].replace(/f6=\d/, 'f6=a') + ";path=/;domain=.youtube.com"; } location.reload(); } } })();