de-styling Google Cached pages
|
|
Hi there,
While testing for results i found something disturbing: it doesn't check for Google Cached pages! eg. if you search for "CSI S09E5 rapidshare.com", you'll get some results from some blogs and forums. I always click on "Cached" to get a fast cached page. However, the results are highlighted with colors and the script is not working. Well, here is a solution i wrote (and tested):
//// my de-styling routine
const destyling = 'yes'; //You can put this line in the options block, at the beginning of the script.
if ((destyling == 'yes') && (location.href.search("q=cache") != -1)) {
var mybody = document.getElementsByTagName('body');
if (mybody[0].innerHTML.search("rapidshare.com") != -1) {
mybody[0].innerHTML = mybody[0].innerHTML.replace(/<b style.*?>/gi,'');
}
}
//// end of my de-styling routine
Add these lines AFTER "//google de-bold end" comment. The code strips off the color highlighting so your script can find and check the rs links. I'm not experienced javascript coder so you may refactor the code for speed and, maybe, add it in the next version of RLC. ;) Regards,
|
|
|
Nice, thanks I will add it, in some days I'll upload a new version. |