In this chapter, we have learned the following:
• Forms are the primary method used for entering data into a browser.
• Forms have a variety of controls that are used for entering different types of inform-
• HTML5 has a large number of new input types that are beginning to be implemented
in modern browsers.
• document.forms will return an HTML collection of all the forms on a page.
• form.elements will return an HTML collection of all the elements contained
within a form.
• Forms have focus , blur , and change events that fire as a user interacts with the
• Forms also have a submit event that can be used to intercept a form before it has
• The information entered into a form can be read or updated using the value prop-
erty of the form controls.
• The HTML5 form validation API can be used to automatically validate a form, but
only at a basic level, so a custom validation script may be required.
In the next chapter, we'll look at the window object.
Search WWH ::