greasemonkey

posted by tom / June 06, 2005 /

I mentioned GreaseMonkey the other day, and promised future evangelism, complete with wild-eyed predictions about how it's going to Change The Internet Forever. Well, here we go.

So what is GreaseMonkey? It's a Firefox extension. You might have some of these already -- there are all kinds of cool extensions available here. You can hook the browser up to your favorite download manager, or control your MP3 playback without leaving the browser, or simplify blogging, or automatically strip out ads from a list of banned domains (e.g. doubleclick.net). There's plenty of great stuff to be had. Personally, I've got an extension installed that adds IE's "Copy Image" function to the context menu; another that improves javascript debugging; and a third that lets me quickly switch between proxy servers.

Anyone can develop extensions, but I wouldn't call it easy. They're written in Javascript, but the amount of packaging overhead that's necessary is discouraging, and the means of interacting with the browser are somewhat poorly documented -- occasionally, they're downright broken (e.g. Firefox's XML-RPC capabilities). In my experience, writing an extension to customize the browser is a frustrating process with a significant learning curve.

That's where GreaseMonkey comes in -- it's designed to allow simple per-site scripts, with a minimum of packaging mumbo-jumbo. You can't do as much as you can with a full-fledged extension, but you can do enough. The barrier to writing code is lowered, and the potential havoc that can be wrought by a malicious script author is limited.

The result is that you can find lots of one-off GreaseMonkey scripts that improve the way different websites work. There's a script to hook IMDB up to your personal NetFlix queue; there's another that rewrites every Amazon link you encounter to use your personal referral code; there's one for Friendster that displays users' profile pictures whenever you put the cursor over an appearance of their names; and there are tons of one-off scripts that strip the advertising out of various sites. You can find a list of available scripts here (although it seems to be down at the moment -- the Google Cache is here).

Installing and managing scripts is easy, too. Just read the GreaseMonkey instructions -- they're pretty straightforward (and very short). You can specify which site or sites each script works on, and GreaseMonkey puts a smiley monkey face in the browser's lower right corner that you can click to turn the extension off altogether.

So count me as a fan. The potential of this extension is huge -- it just needs more people writing scripts. If you know any Javascript it's pretty easy, and actually wouldn't be a bad "learning to program" sort of project. In fact, I dashed off an (admittedly buggy) script this afternoon -- click here if you want to try it out. Impressed by her guest-spot at Scary Go Round, I checked out Vera Brosgol's online comic Return To Sender -- and was dumb enough not to notice the teeny-tiny navigation links at the bottom of each page. So I wrote a script that adds more obvious navigation buttons near each page's top.

Useless? Mostly, yeah. But have a look at the amazing Platypus Firefox extension -- an incredible piece of code that lets you write GreaseMonkey scripts using a simple graphical interface. If I can dash off a script in half an hour, and anyone can build one using WYSIWYG tools, web surfers are very close to being put in full control of their internet experience.

It's Tivo for the internet, and I think it's going to be big.

UPDATE: Yeah, so that script isn't very good -- it doubles up the strip sometimes. Oh well. It works, and given the previously mentioned uselessness, I'm not likely to fix it.

Post A Comment

Name


Email Address


URL


Comments


Remember info?



Google Analytics