View greasemonkey ignore script
Just for the fun of it, here’s a greasemonkey recipe:
The basic script to run jQuery inside of greasemonkey is found here: How to play nicely with jQuery and Greasemonkey
It’s not nice to leech bandwidth of the jQuery folks, so please replace the link in the GM_JQ.src assignment with a local copy or have Les host it or ask me nicely and I may just host a public copy myself.
You’ll want to replace this
function letsJQuery() {
alert($); // check if...
}
with something like this
function letsJQuery() {
// ignore twits on sidebar
$("p:has(>span.author:contains(TWIT'S NAME))").remove();
// ignore twits on comment pages
$("div:has(>div.posted:contains(TWIT'S NAME))").remove();
}
Copy and paste as needed for more than one twit or set up an array and iterate over it.
Human-readable translation of the code:
sidebar: remove all P elements that have a SPAN containing the string TWIT’S NAME as a direct descendant.
comments: remove all DIV elements that have a DIV with class “posted” as a direct descendant that contains the string TWIT’S NAME.
By the way, there’s a subtly different variation of the selector:
function letsJQuery() {
// ignore twits on sidebar
$("p:has(>span.author):contains(TWIT'S NAME)").remove();
// ignore twits on comment pages
$("div:has(>div.posted):contains(TWIT'S NAME)").remove();
}
which will remove all sidebar blurbs and comments that even mention the twits.