CineZone Trailers

generates 'Trailer' links that will open a video trailer for movies and TV shows, using YouTube, in a popup window

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

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

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

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

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

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @name         CineZone Trailers
// @namespace    http://tampermonkey.net/
// @version      1.1
// @description  generates 'Trailer' links that will open a video trailer for movies and TV shows, using YouTube, in a popup window
// @match        *://cinezone.to/*
// @match        *://www*.cinezone.to/*
// @match        *://www.cinezone.to/*
// @match        https://flixflare.to/*
// @require      https://code.jquery.com/jquery-3.7.0.min.js
// @license      CC-BY-NC-SA-4.0
// @icon https://www.google.com/s2/favicons?sz=64&domain=cinezone.to
// @author       drhouse
// ==/UserScript==
this.$ = this.jQuery = jQuery.noConflict(true);
jQuery(function($){

    var title = $("h1[itemprop='name']").text().trim();

    var siteLink = document.createElement('a');
    siteLink.innerHTML = '<b>[ Trailer ]</b>';
    siteLink.setAttribute('href', 'https://www.google.com/search?q=site%3Ayoutube.com+' + encodeURIComponent(title) + '+trailer&btnI=I%27m+Feeling+Lucky');
    siteLink.setAttribute('class', 'nframe');
    siteLink.style.fontSize = 'inherit';

    var insert = $("h1").first();
    // $(insert).append(siteLink).append("<br>");
     $(insert).after(siteLink).append("<br>");

    $(".nframe").click(function (e) {
        e.preventDefault();
        var url = $(this).attr("href");

        var width = screen.width * 0.75;
        var height = screen.height * 0.75;
        var left = (screen.width - width) / 2;
        var top = (screen.height - height) / 2;
        var params = 'width=' + width + ', height=' + height;
        params += ', top=' + top + ', left=' + left;
        params += ', directories=no';
        params += ', location=no';
        params += ', menubar=no';
        params += ', resizable=yes';
        params += ', scrollbars=yes';
        params += ', status=no';
        params += ', toolbar=no';
        var newwin = window.open(url, 'subpop', params);
        if (window.focus) {
            newwin.focus()
        }
        return false;
    });
});