Sometimes, you just want to read the important stuff on a page. Here's a JavaScript sniplet that will do this for you:

Zap images

Drag it to your bookmarks and click on it whenever you want to hide all the pictures on the current page you're visiting.

Here's the source:

[sourcecode language=jscript]javascript:(function(){var imgs=document.getElementsByTagName(‘img');var imgArr=[];for(var i=0;i<imgs.length;i++){imgArr.push(imgs[i]);} for(i= 0;i<imgArr.length;i++){var txt=document.createTextNode(imgArr[i].alt);imgArr[i].parentNode.replaceChild(txt,imgArr[i]);}})();[/sourcecode]

UPDATE: Kai√Ǭ†showed a shorter version of the code in the comments, so I updated the post… the current code is the new hotness

Comments