您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Generate new random episode every time you press random episode without refresh the page!
当前为
// ==UserScript== // @name thewatchseries.to Random Episodes Button // @namespace RandomEpisodesButton // @version 0.1 // @description Generate new random episode every time you press random episode without refresh the page! // @author jscriptjunkie // @match http://thewatchseries.to/* // @grant none // ==/UserScript== /* jshint -W097 */ 'use strict'; $('.random_inside a').attr('href','#'); $('.random_inside').click(function () { var website = 'http://thewatchseries.to'; var obj = $(this).parent().next(); var numberOfEpisonds = obj.children().length; var rnd = 1 + Math.floor(Math.random() * numberOfEpisonds); var episodeLink = website + obj.find('li:nth-child('+rnd+') a').attr('href'); window.open(episodeLink, '_blank'); });