Type in a command, or "ls dictionary" to search all commands for "dictionary", etc.

bookmarklet2addscript

echo <a href="javascript:(function()%7Bvar s=document.createElement('script');s.setAttribute('src','${path}');document.getElementsByTagName('body')[0].appendChild(s);%7D)()">%s</a>
bookmarklet2addscript (read 'bookmarklet to add script')
Generates a bookmarklet that will load a specific javascript file when clicked. Useful when you want to test javascript libraries on other's webpage.

Syntax:
 bookmarklet2addscript [name] -path [path]

Example:
 bookmarklet2addscript Latest jQuery -path http://jquery.com/src/jquery-latest.pack.js
 << generates a bookmarklet that let you load the latest jQuery javascript library.

 bookmarklet2addscript jQuery 1.1 -path http://jquery.com/src/jquery-1.1.js
 << This time, jQuery version 1.1. 
    After you drag the bookmarklet to your browser toolbar,
    visit Google and enter the following code in the browser addressbar.
    javascript:(function(){$('a').css('background','yellow');})()
    Or, if your browser has a javascript console, enter the following in the console.
    $('a').css('background','yellow');
    Then all links will get yellow background.


Based on the code I found from:
http://www.learningjquery.com/2006/12/jquerify-bookmarklet

Tested on Firefox 2, Opera 9, IE 7 on Windows XP.
    
72 uses - Created 2007-01-20 18:19:55 - Last used 2015-05-07 08:56:37
Is this command broken? Tell Jon if you know how to fix it.
Do you find this command offensive? Let Jon know.