Now the above code snippet means on clicking the div.#foobar the background of all divs is changed to red.Now there is a variety of stuffs you can with jquery check here.Now i used Jquery in the menu of events visible in the site.I have given all the event rules as JSON files and on clicking a link it fetches the corresponding JSON file asynchronously.
There are also variety of pluggins availabe in jquery you can use for your benefut like calendar,animation etc.
Now this is the code i use to perform the JSON operations.
var filename=’json/’+ name + ‘.json’;
var html=’add the html stuff here with JSON data say event[‘name’]’