SquirrelTo 0.3 for Opera UserJS
Written on July 18, 2008
My hosting company provides webmail access with SquirrelMail. In the last few years I’ve taken to only using webmail and not even having a mail client installed on most of my machines. Why bother with downloading all that mail directly to my computer. My host provides plenty of storage for cheap, so why not just keep all my mail on the server?
So anyway the problem comes up when you click on a mailto link on some web page. These are becoming pretty uncommon these days as they tend to attract spambots to the address they point to. When I do click on one, the browser always ends up spinning it’s wheels launching Outlook Express or Evolution or whatever the default mail client is on that machine. I need a way to just open up the web page to write a mail with SquirrelMail.
The Opera Web Browser has a nice little feature for hackers like me… You can install javascript scripts that modify pages as you view them to tweak them to your own preferences or add new features to your user experience.
squirrelTo is my solution to the problem. squirrelTo re-writes mailto on web pages as you browse them and turns them into links that will open a compose window in your squirrelMail server to the address pointed to in the mailto link.
To use this script, save it to your Opera User JS directory and, very important edit the following lines:
/********************* Configure options here *********************/ // Change this variable to point to your squirrelmail install var squirrelPath = "http://example.com/path/to/squirrelmail/src/";
You must change the “http://example.com/path/to/squirrelmail/src/” to the corresponding address and path of your squirrelMail instance for this to work at all. Also, it only works you are already logged into your squirrelMail server when you click on the link. If not, it just takes you to the login page of you your server.
Download SquirrelTo 0.3 for Opera UserJS here Right click on this link and choose to save the target to your UserJS folder. If you’re not familiar with Opera UserJS, I suggest you check out this tutorial here.
Oh yeah - for greasemonkey users… I haven’t tried it with greasemonkey and I bet it doesn’t work, but I bet it wont be too hard to make it work or copy the idea. If you convert this to greasemonkey let me know and I’ll link to your script or bring in your changes…
Filed in: Geek, Open Source, Opera.