您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Makes JWPlayer think that you don't have the Flash plugin, thus forcing HTML5 mode
- // ==UserScript==
- // @name JWPlayer Force HTML5
- // @namespace DoomTay
- // @description Makes JWPlayer think that you don't have the Flash plugin, thus forcing HTML5 mode
- // @version 1.0.1
- // @grant none
- // @include *
- // @exclude http://roosterteeth.com/*
- // @run-at document-start
- // @noframes
- // ==/UserScript==
- var observer = new MutationObserver(function(mutations) {
- mutations.forEach(function(mutation) {
- for(var i = 0; i < mutation.addedNodes.length; i++)
- {
- findJWPScript(mutation.addedNodes[i]);
- if(typeof window.jwplayer !== 'undefined') break;
- }
- });
- });
- for(var i = 0; i < document.scripts.length; i++)
- {
- findJWPScript(document.scripts[i]);
- if(typeof window.jwplayer !== 'undefined') break;
- }
- function findJWPScript(start)
- {
- if(start.nodeName == "SCRIPT" && start.src && typeof window.jwplayer === 'undefined')
- {
- start.addEventListener("load",function()
- {
- if(typeof window.jwplayer !== 'undefined')
- {
- observer.disconnect();
- if(window.jwplayer.utils.hasFlash) window.jwplayer.utils.hasFlash = function (){return!1};
- if(window.jwplayer.utils.isFlashSupported) window.jwplayer.utils.isFlashSupported = function (){return!1};
- if(window.jwplayer.utils.flashVersion) window.jwplayer.utils.flashVersion = function (){return 0};
- }
- });
- }
- else if(typeof window.jwplayer === 'undefined')
- {
- for(var i = 0; i < start.childNodes.length; i++)
- {
- findJWPScript(start.childNodes[i]);
- }
- }
- }
- var config = { childList: true, subtree: true };
- if(typeof window.jwplayer == 'undefined') observer.observe(document, config);
QingJ © 2025
镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址