磁力快显

在磁力宝、磁力管家、Skrbt网站的磁力搜索列表增加磁力链接显示,方便下载资源。

目前為 2020-03-10 提交的版本,檢視 最新版本

// ==UserScript==
// @name         磁力快显
// @namespace    http://tampermonkey.net/
// @description  在磁力宝、磁力管家、Skrbt网站的磁力搜索列表增加磁力链接显示,方便下载资源。
// @author       zxf10608
// @version      1.4
// @homepageURL  https://gf.qytechs.cn/zh-CN/scripts/397490
// @require      https://cdn.bootcss.com/jquery/1.8.3/jquery.min.js
// @include      *://cilibao.biz/*
// @include      https://www.ciliguanjia.icu/*
// @include      *://skrbt*.icu/*
// ==/UserScript==

(function() {
	
	var href1 = location.href.indexOf('cilibao');
	var href2 = location.href.indexOf('ciliguanjia');
	var href3 = location.href.indexOf('skrbt');
		
	if (href1 != -1 || href2 != -1 || href3 != -1) {
        var magnet2 = function() {
			if (href3 != -1) {
				var hrefx = '.result-resource-title';//减少干扰元素
				$('.result-resource-meta-info').find("a:contains('磁力链接')").hide();//隐藏原有假“磁力链接”
					} else {
					var hrefx = 'a[href*=\'detail\'],a[href*=\'cili-\']';
					}
				
                $(hrefx).each(function() {
					if($(this).attr('href').indexOf('cili-')>0){
					$(this).attr('href', $(this).attr('href').replace('/cili-', '/detail/'));
					}
                    var torrent2Href = $(this).attr('href');
					var temp2Link = torrent2Href.split('/detail/');
					if (href3 != -1) {	
							var href2Magnet = 'magnet:?xt=urn:btih:' + temp2Link[1].substring(6,46);	
							} else {
								var href2Magnet = 'magnet:?xt=urn:btih:' + temp2Link[1].substring(0,40);
								}
					$(this).after('<a href="' + href2Magnet + '" target="_blank">&nbsp;&nbsp;磁力链接</a>');
					$('.search-tips').hide();//隐藏多余元素
                });
		};
		magnet2();
	};
})();

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址