Saturday, April 24, 2010

[Learning by doing] GreaseMonkey

Learning by doing’ is a new series of posts to help the readers of Varun’s Scratchpad in learning some exciting things and to share my knowledge with them. I always believe in ‘learning by doing’ methodology. To learn something new in technology, I prefer implementing a small known problem rather than going through the documentation or reading tutorials. Of course, this approach may not work out in all the cases. In this series of posts, I will be posting specific problems for you to try out. By implementing those problems, you can learn the technology behind them. The first post on this series is going to be about learning GreaseMonkey. In fact, I learnt GreaseMonkey by writing a Sudoku game inside GMail interface.

GreaseMonkeygmlogo

GreaseMonkey was originally written as a Firefox add-on which allows you to write custom script on top of any web page. It helps you to add custom functionalities, features to your favorite websites. For example, if you don’t like the theme of a website, you can customize it to your liking. Being the big GreaseMonkey fan that I am, have written many scripts for my personal use and also for common use cases. Check out all my public GreaseMonkey scripts here.

Try it out yourself

Varun uses GMail web chat for chatting with his friends. While chatting with friends, he visits other websites and do some random stuffs on the web.  GMail web client has the sound notification feature which is quite useful for him as he is working on multiple things. But, he does not like the notification ringtone which GMail uses by default. GMail provides a way of turning it off but there is no way for him to choose a different ringtone. Help Varun by writing a GreaseMonkey script which allows him to change the ringtone. 

P.S: I have a working implementation of this script. Ping me if you need any assistance in implementing this.

-- Varun

4 comments:

  1. I thought you will start with a "Hello World" example and will ask people to implement "Remove the GMail ads" ;-)

    BTW, in your template, "Leave a response" does not seem to work. I had to search to leave a comment.

    ReplyDelete
  2. @Sankar: This problem is a suitable one for learning lots of things about GreaseMonkey. Thatz y chosen this. :-)


    About "Leave a response" link:
    Thanks for letting me know abt that. Shall check n fix that.

    Thanks.

    ReplyDelete
  3. What up with addressing yourself in third person :-)

    ReplyDelete
  4. @Vengu: Just used my name for the problem statement.. :)

    ReplyDelete