Greasy Fork

Greasy Fork is available in English.

zimuzu.tv 批量复制迅雷链接

字幕组选择迅雷下载

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Greasemonkey 油猴子Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Userscripts ,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

// ==UserScript==
// @name         zimuzu.tv 批量复制迅雷链接
// @namespace    dishuostec
// @version      0.3.1
// @description  字幕组选择迅雷下载
// @author       dishuostec
// @match        http://www.zimuzu.tv/gresource/list/*
// @match        http://www.zimuzu.tv/resource/list/*
// @match        http://www.zmz2017.com/gresource/list/*
// @match        http://www.zmz2017.com/resource/list/*
// @grant        GM_setClipboard
// ==/UserScript==

function get_xunlei(){
    var urls = [];
    var anchor_text = $(this).data('text');
    $(':checkbox:checked').each(function(){
        var $link = $(this).closest('li').find('a:contains("'+anchor_text+'")');
        urls.push($link.attr('href'));
    });

    GM_setClipboard(urls.join('\n'));
    alert('复制了'+urls.length+'个链接');
}

$(function(){
    var $thunder_ed2k = $('<a ref="thunder" data-text="迅雷-电驴" style="background-color:red">[全部-迅雷-电驴]</>');
    var $thunder_magnet = $('<a ref="thunder" data-text="迅雷-磁力" style="background-color:red">[全部-迅雷-磁力]</>');
    $thunder_ed2k.on('click', get_xunlei);
    $thunder_magnet.on('click', get_xunlei);
    $('.media-control').find('a').last().after($thunder_ed2k).after($thunder_magnet);
});