Tinychat Cleanup

After stylebot (http://stylebot.me/styles/10932) + ABP, remove the other spam.

09.02.2017 itibariyledir. En son verisyonu görün.

Bu betiği kurabilmeniz için Tampermonkey, Greasemonkey ya da Violentmonkey gibi bir kullanıcı betiği eklentisini kurmanız gerekmektedir.

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

Bu betiği kurabilmeniz için Tampermonkey ya da Violentmonkey gibi bir kullanıcı betiği eklentisini kurmanız gerekmektedir.

Bu betiği kurabilmeniz için Tampermonkey ya da Userscripts gibi bir kullanıcı betiği eklentisini kurmanız gerekmektedir.

Bu betiği indirebilmeniz için ayrıca Tampermonkey gibi bir eklenti kurmanız gerekmektedir.

Bu komut dosyasını yüklemek için bir kullanıcı komut dosyası yöneticisi uzantısı yüklemeniz gerekecek.

(Zaten bir kullanıcı komut dosyası yöneticim var, kurmama izin verin!)

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.

(Zateb bir user-style yöneticim var, yükleyeyim!)

// ==UserScript==
// @name         Tinychat Cleanup
// @namespace    http://www.JamesKoss.com/
// @version      17.11.2016
// @description  After stylebot (http://stylebot.me/styles/10932) + ABP, remove the other spam.
// @author       JamesKoss.com
// @match        http://tinychat.com/*
// ==/UserScript==

(function() {
    'use strict';
    
    var el1 = document.querySelectorAll('div[id^="div-gpt-ad-"]')[0];
    el1.parentNode.removeChild(el1);
    var el2 = document.querySelectorAll('script[src="/public/js/ads.js"]')[0];
    el2.parentNode.removeChild(el2);
    var el3 = document.querySelectorAll('script');
    for (var x in el3) {
        var y = el3[x];
        if (y.outerHTML) {
            // All scripts to be removed.
            if (y.outerHTML.indexOf('function checkAds') !== -1 ||
                y.outerHTML.indexOf('_cc7034') !== -1 ||
                y.outerHTML.indexOf('crwdcntrl') !== -1 ||
                y.outerHTML.indexOf('googleads') !== -1 ||
                y.outerHTML.indexOf('adnxs') !== -1) {
                y.parentNode.removeChild(y);
            }
        }
    }
    var el4 = document.querySelectorAll('iframe[id="iframe_ad"]')[0];
    el4.parentNode.removeChild(el4);
})();