Events

Unit 10

Event examples

sample-1-event-examples shows event examples.
sample-2-button-examples shows buttons used to link to a new page.

Reading assignment

Reading assignments are in the text book, Java Script, A Beginner's Guide, Second Edition, by John Pollock; McGraw Hill / Osborne, ISBN 0-07-222790-7

Read Module 7.

Read section 7.1 - Remember that WE are using XHTML, so the element names and attributes must be spelled in lower case. Example:
<button type="button" onclick="window.alert('Hi!');"  />
Also, remember to use the space-slash at the end of a singleton tag.
Read section 7.2 - Again, remember to spell the Event Handler names in all lower case.
Read section 7.3 - There may be some problems with changing the status bar in recent browsers. There are some interesting examples in the book.

Alternate reading assignments are in the text book, Java Script Concepts & Techniques Programming Interactive Web Sites, by Tina Spain McDuffie; Franklin, Beedle & Associates, ISBN 1-887902-45-7

Read Chapter 5. Understand what event handlers are. Know the different kinds of event handlers. Do NOT read the details of the code that handles the events. This code uses the Document Object Mode. We will study the Document Object Model, and then return to look at the code that executes when an event is handled. For know, you just need to know the code you put in your html file, that calls the event handler.

Lecture notes

Do NOT read the lecture notes before hearing the lecture. If you do, you will find the lecture very boring. Read the lecture notes if you do not attend the lecture, or if you wish to review the material.