O'Reilly logo

jQuery, jQuery UI, and jQuery Mobile: Recipes and Examples by Adriaan de Jonge

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 4. Listening and Responding to Events

Listening and responding to events using jQuery is relatively simple in terms of code. Regardless of the code’s simplicity, however, handling events can still be complex. Large numbers of events are generated in seemingly unpredictable order. To be able to respond to events in a useful manner, you need a grasp of which events you can expect, under what circumstances. This chapter provides recipes with which you can log all events of a certain kind and experiment with your input to see what happens. It handles mouse events, keyboard events, form events, and some more general events such as scrolling. After investigating specific events, this chapter demonstrates the advantages of event delegation. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required