Greasy Fork

Greasy Fork is available in English.

IT之家资讯列表广告屏蔽 ithome CPS Filter

移除IT之家(ithome.com)资讯列表内投放的购物广告;Remove CPS Ads in ithome.com's news list.

目前为 2018-03-28 提交的版本,查看 最新版本

// ==UserScript==
// @name                IT之家资讯列表广告屏蔽 ithome CPS Filter
// @name:zh-CN          IT之家资讯列表广告屏蔽
// @description         移除IT之家(ithome.com)资讯列表内投放的购物广告;Remove CPS Ads in ithome.com's news list.
// @description:zh-CN   移除IT之家(ithome.com)资讯列表内投放的购物广告。
// @version             0.9
// @author              YvesX https://www.yvesx.com
// @namespace           https://github.com/Yves-X
// @contributionURL     https://www.yvesx.com/go/donate/ 
// @match               *://www.ithome.com/*
// @grant               none
// ==/UserScript==
(function () {
    'use strict';
        var newsSpan = $('.title').children('a');
        newsSpan.each(function (i) {
            var newsUrl = $(this).attr("href");
            if (newsUrl.indexOf('lapin') >= 0) {
                $(this).parent().parent().html(' ');
            }
        });
})();
(function () {
    'use strict';
        var newsSpan = $('.title').children('a');
        newsSpan.each(function (i) {
            var newsUrl = $(this).attr("href");
            if (newsUrl.indexOf('lapin') >= 0) {
                $(this).parent().parent().html(' ');
            }
        });
})();