##Bookmarklets
#####What is it?
- An anonymous JS function
- Saved in the url of a bookmark in your browser
- Can also reference an external file
#####What can it be used for?:
- Hide the subscription blocker on NYT
- Fill in forms for you
- Idle Games
- Download a YouTube video
- Accept all gifts in a Facebook game
#####Hello World Bookmarklet
-
Make your bookmarks bar visible: In Chrome > View > Always Show Bookmarks Bar
-
Add a new bookmarklet Right click on your Bookmarks Bar > Add Page
-
Edit your bookmarklet (The fields will be autofilled with the title and url of your current page)
Edit the title and url and then save it. Be careful - spaces are important!
javascript:(function(){ alert("herrow world") }) ()
- Click on your bookmarklet "HERROW!!"
- (Optional) If the above steps aren't working for you, try the Bookmarklet Crunchinator site.
It will wrap your JS code in an anonymous function as well as doing other formatting for you.
-Click on the "Your Bookmarklet" link to test it. -Then, drag the 'Your Bookmarklet' link to your bookmarks bar. -Click on it to run it.
#####Why use a bookmarket instead of an extension?
- Doesn't give external devs access to your browser "your personal information, and all pages you visit"
#####Helpful links Bookmarklet Crunchinator | TutsPlus - Tutorial | Make your own bookmarklets with JQuery