Eight Weeks of Prototype: Week 4, Event Handling in Prototype
Summary
In this article I've shown you how to handle JavaScript events using the helpful methods Prototype provides. Not only did I show you how to handle normal DOM events, but I also showed you how to use custom events and where it may be useful to do so.
There were a wide range of examples in this article, including demonstrating how to handle keyboard and mouse events.
In the sixth article in this series I'll show you to create classes in JavaScript, which really helps with organising all of your event handlers together.
In the next article though, I'll show you how to perform Ajax requests using Prototype. This will include a number of different examples and cover a wide range of topics including how to easily communicate with server-side scripts using JSON and how to build accessible forms that use Ajax.
Other Options
- Download a PDF version of this article
- View or post comments for this article
- Browse similar articles by tag: JavaScript, Prototype
-
Read related articles:
- Eight Weeks of Prototype: Week 1, Beginning with Prototype
- Eight Weeks of Prototype: Week 2, How Prototype Extends Elements
- Eight Weeks of Prototype: Week 3, Prototype Data Types
- Eight Weeks of Prototype: Week 5, Ajax with Prototype
- Eight Weeks of Prototype: Week 6, Writing JavaScript Classes with Prototype
- Eight Weeks of Prototype: Week 7, Other Prototype Functionality
- Eight Weeks of Prototype: Week 8, A Complete Prototype Example



