Dropbooks Romover

Remove ads and skip datail page on Dropbooks

Version vom 14.05.2017. Aktuellste Version

Du musst eine Erweiterung wie Tampermonkey, Greasemonkey oder Violentmonkey installieren, um dieses Skript zu installieren.

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.

Sie müssten eine Skript Manager Erweiterung installieren damit sie dieses Skript installieren können

(Ich habe schon ein Skript Manager, Lass mich es installieren!)

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               Dropbooks Romover
// @namespace          http://hogehoge/
// @version            1.*
// @description        Remove ads and skip datail page on Dropbooks
// @description:ja     ドロップブックスの広告の削除・詳細ページのスキップ
// @author             H. Amami
// @match              *://dropbooks.tv/*
// @grant              none
// ==/UserScript==

function deleteThis(obj) {
    obj.parentNode.removeChild(obj);
}

if (location.href.indexOf("/detail/") === -1) {
    deleteThis(document.getElementById("main2col").getElementsByTagName("center")[0]);
    deleteThis(document.getElementsByClassName("content_list")[0]);
    deleteThis(document.getElementById("ad_tsuibi"));
    var a = document.getElementsByTagName("a");
    var h = "";
    for (var i = 0, max = a.length; i < max; i++) {
        h = a[i].href;
        if (h.indexOf("/detail/") > -1) {
            a[i].href = h.replace("/detail/", "/detail/download_zip/");
        }
    }
}

var cnt = 0;

function b() {
    d = document.getElementById("octopus-scr");
    if (d) {
        clearInterval(c);
        deleteThis(d);
        document.body.style.paddingTop = 0;
    }
    if (++cnt > 5) clearInterval(c);
}

var c = setInterval(b, 500);