Replace "Bush" with "Monkeyboy"
From Chickenfoot Script Repository
Here's my first script, best used at, say, CNN.com or nytimes.com:
// ==UserScript==
// @name Replace Bush with Monkeyboy
// @when Pages Match
// @description replaces bush with monkeyboy in all text nodes
// @include http://www.cnn.com/*
// @include http://www.nytimes.com/*
// ==/UserScript==
for (word = new find(new TC('word'));
word.hasMatch;
word = word.next)
{
if (word == 'Bush')
replace(word, "Monkeyboy")
}
It hogs a lot of CPU though. Is there a way to use a background thread so that Firefox doesn't freeze up during the search?
