Primewire Host Highlighter

Automatically highlights the provider or host of your choice wherever it appears on a page listing, allowing you to quickly locate and click your favorite host to start watching.

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey, Greasemonkey किंवा Violentmonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey किंवा Violentmonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल..

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey किंवा Violentmonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल..

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

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल..

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्क्रिप्ट व्यवस्थापक एक्स्टेंशन इंस्टॉल करावे लागेल.

(माझ्याकडे आधीच युझर स्क्रिप्ट व्यवस्थापक आहे, मला इंस्टॉल करू द्या!)

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

(माझ्याकडे आधीच युझर स्टाईल व्यवस्थापक आहे, मला इंस्टॉल करू द्या!)

// ==UserScript==
// @name Primewire Host Highlighter
// @namespace PHH
// @description Automatically highlights the provider or host of your choice wherever it appears on a page listing, allowing you to quickly locate and click your favorite host to start watching.
// @version 1.1
// @run-at  document-ready
// @include https://www.primewire.ag/*
// @grant        GM_getValue
// @grant        GM_setValue
// @grant        GM_deleteValue
// @grant        GM_registerMenuCommand
// @grant        GM_notification
// @require http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js
// @author drhouse
// @icon https://www.primewire.ag/favicon.ico
// ==/UserScript==

$(document).ready(function () {

	GM_registerMenuCommand("Primewire Host Highlighter", function(){
		var host = GM_getValue("highlight"); 
		host = prompt ('Enter hostname (case insensitive):', host);
		GM_setValue ("highlight", host);
		location.reload();
	});

	$.expr[":"].icontains = $.expr.createPseudo(function(arg) {
		return function( elem ) {
			return $(elem).text().toUpperCase().indexOf(arg.toUpperCase()) >= 0;
		};
	});

	var host = GM_getValue("highlight"); 
	if (!host){
		host = "vidzi";
	}

	var target = $('#first > table:icontains('+ host +')');
	$(target).css('background-color', 'yellow ');

	var targetx = $(target).find('.movie_version_link a').attr('href');
	var link = 'https://www.primewire.ag/' + targetx;

	var r = $('<input/>', { type: "button", id: "field", value: " "+ host +" " });
	$(r).css("position","fixed");
	$(r).css("top","20px");
	$(r).css("left","200px");
	$(r).insertBefore(".header_search");

	$( r ).click(function() {
		var win = window.open(link, '_blank');
		var title = $('body > div.container > div.main_body > div.col1 > div.index_container > div.stage_navigation.movie_navigation > h1 > span > a').text();
		var msg = new SpeechSynthesisUtterance('Now opening ' + title);
		window.speechSynthesis.speak(msg);
		GM_notification("Opening " + title, "AutoHost Play", null, function() {/* */});
	})

});