Sunday, June 10, 2007

Prototype bookmarklet

I find myself relying on Prototype quite a bit. So I added this bookmarklet to every browser I use (to the Links folder in IE, and the Bookmarks Toolbar Folder in Firefox) so I can enable it in whichever page I need. It's a poor man's replacement for Greasemonkey in IE.


javascript:(function(){var head,script; if(!document.getElementById('prototype.js')){head=document.getElementsByTagName('head')[0]; script=document.createElement('script'); script.type='text/javascript'; script.src='http://.../prototype.js'; script.id='prototype.js'; head.appendChild(script);}})(); void(0);


Replace the "..." in the URL with a location inside your network, on your localhost, or otherwise under your control.

No comments: