Last active
September 27, 2020 20:49
-
-
Save gene1wood/74a0383a8ec145131144 to your computer and use it in GitHub Desktop.
Greasemonkey User Script to hide sponsored posts on boingboing.net
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Block Boing Boing Ads | |
// @namespace http://cs.cementhorizon.com | |
// @description Block Boing Boing Ads | |
// @include http://boingboing.net/* | |
// @include https://boingboing.net/* | |
// @require http://ajax.googleapis.com/ajax/libs/jquery/2.1.0/jquery.min.js | |
// @version 5 | |
// @grant none | |
// ==/UserScript== | |
$("div.fromtheshop").hide() | |
$("div#widgets div.widget_stackcommerce_widget").hide() | |
// Note the leading space in the href which looks like a typo in the boingboing code | |
$("article div a.category[href=' https://boingboing.net/tag/sponsored']").parent().parent().hide() | |
// $("div h2 a.byline[href='https://boingboing.net/author/ruben_bolling']").parent().parent().hide() | |
// $("div h2 a.byline[href='https://boingboing.net/author/wimpyrutherford']").parent().parent().hide() | |
// $("div h2 a.byline[href='https://boingboing.net/author/boingboingstore']").parent().parent().hide() | |
// | |
// $("article a.byline[href='https://boingboing.net/author/boingboingstore']").parent().parent().hide() | |
// $("article a.byline[href='https://boingboing.net/author/wimpyrutherford']").parent().parent().hide() | |
// $("article a.byline[href='https://boingboing.net/author/ruben_bolling']").parent().parent().hide() | |
// $("article a.byline[href='https://boingboing.net/author/petersheridan']").parent().parent().hide() | |
$("a.byline[href='https://boingboing.net/author/petersheridan']").parent().parent().hide() | |
$("a.byline[href='https://boingboing.net/author/boingboingstore']").parent().parent().hide() | |
$("a.byline[href='https://boingboing.net/author/wimpyrutherford']").parent().parent().hide() | |
$("a.byline[href='https://boingboing.net/author/ruben_bolling']").parent().parent().hide() | |
$("a.byline[href='https://boingboing.net/author/sponsoredpost']").parent().parent().hide() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Great suggestion, I didn't know about
/blog
. I've added the filters for that page as well (though in a slightly different way than you suggest, just to be more targeted)