IMDB - add tracker links

at bottom-right of page

目前為 2015-06-25 提交的版本,檢視 最新版本

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

You will need to install an extension such as Tampermonkey to install this script.

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

// ==UserScript==
// @name        IMDB - add tracker links
// @description at bottom-right of page
// @namespace   KG
// @include     http*://*imdb.com*tt*
// @run-at	document-start
// @grant	GM_addStyle
// @version     1.3
// ==/UserScript==

var sites = [
"https://karagarga.in/browse.php?search_type=imdb&search=",
"https://cinemageddon.net/browse.php?search=tt",
"http://cinematik.net/browse.php?cat=0&incldead=1&sort=1&type=asc&srchdtls=1&search=tt",
"https://passthepopcorn.me/torrents.php?searchstr=tt",
"https://broadcasthe.net/torrents.php?imdb=tt",
"http://www.opensubtitles.org/en/search/sublanguageid-all/imdbid-tt"
];

var names = ["KG", "CG", "Tik", "PTP", "BTN", "OS"];

// don't run in iframes
if (!window.frameElement) {
	var h = document.location + "";
	var q = h.split('/tt')[1] + "";
	var ref = q.substr(0, 7);

	doIt();
}

function doIt() {
    if (!document.body) { 
    	setTimeout(function(){ doIt(); }, 100); 
    	return;
    }

    GM_addStyle(" #linkbar { font-family: sans-serif; font-weight: bold; color: #ccc; background-color: #000; font-size: 0.8em;  padding: 0.5em; position: fixed; right: 0; text-align: left; bottom: 0; z-index: 1000; } ");
    GM_addStyle(" #linkbar a:link, #linkbar a:visited { color: #ccc; text-decoration: none; } ");

    var bar = document.createElement('div');
    bar.id = "linkbar";
    document.body.appendChild(bar);
    
    var openAll = "<a href='#' onclick=\"javascript: ";
    
    for (i=0; i < sites.length; i++) {
    	bar.innerHTML += "<a href='" + sites[i] + ref + "'>" + names[i] + "</a> | ";
    	openAll += "window.open(' " + sites[i] + ref + " ', '_blank'); ";
    }
    
    bar.innerHTML += openAll + " return false; \">ALL</a> ";
}