4 ms·
Ask YC: How do you build a bookmarklet?
I a non-programming founder trying to contribute towards the development of our web app and tonight I was trying to create a javascript bookmarklet to easily submit content to our Social News from my Firefox toolbar. My search skills are not too bad, but I couldn't find something that worked for me. I still have a lot of questions unanswered. Hence I decided to ask you, the all knowing YC crowd.
Any help?
- seregine 18y agoHave you seen this wikipedia page? It has some good references: http://en.wikipedia.org/wiki/Bookmarklet http://en.wikipedia.org/wiki/Bookmarklet The basic idea is that you create a link on your page that points to a "javascript:" URL. This link can become a bookmark just like any other link. The javascript in the link's URL implements your bookmarklet functionality.
- bazookaaa 18y agoLooking at del.icio.us's bookmarklet may be a good start: javascript:location.href='http://del.icio.us/post?v=4;url='+encodeURIComponent(location.href)+';title='+encodeURIComponent(document.title.replace(/%5E%5Cs*%7C%5Cs*$/g,'')) Basically, it redirects the browser to http://del.icio.us/post?v=4 http://del.icio.us/post?v=4 and passes two parameters to the URL: "url" and "title" which just contains the url and the website title of the previous website you were on.
- prakash 18y agoThis one address your question: http://betterexplained.com/articles/how-to-make-a-bookmarklet-for-your-web-application/ http://betterexplained.com/articles/how-to-make-a-bookmarkle...
- ScottWhigham 18y agoThe obvious choice: http://www.google.com/search?q=how+to+build+a+bookmarklet http://www.google.com/search?q=how+to+build+a+bookmarklet