onchange Event Handler But Without An Explicit
Submit Mechanism
User agents often perform a task when an event occurs that is due to user interaction (e.g., document loading, mouse motion or a key press), a request from the operating environment, etc. Some markup languages allow authors to specify that a script, called an event handler, be executed when the event occurs. An event handler is "explicitly associated with an element" when the event handler is associated with that element through markup or the DOM. The term "event bubbling" describes a programming style where a single event handler dispatches events to more than one element. In this case, the event handlers are not explicitly associated with the elements receiving the events (except for the single element that dispatches the events).
This document is part of a suite of pages designed to test the implementation of the W3C's User Agent Accessibility Guidelines (UAAG). In particular, this page is designed to test implementation of UAAG checkpoints 5.4, 9.4, and 9.5:
On this test page, the HTML4 event handler onchange has been associated with a select option
(list box) in a simple, one-field form that lacks an explicit
Submit mechanism.
This page contains a simple, one-field form.
If your user agent supports the ACCESSKEY mechanism introduced in HTML4, you can
instantly establish focus on the list box using the
ACCESSKEY defined for the form, f.
If your user agent supports scripting, and if support for scripting is active, once the select option list box receives focus, changing the displayed option will cause your user agent to fetch the selected Guidelines document.
If you are using a user agent that does not support scripting, or if
you have support for scripting turned off, changing the displayed
option should have no effect other than exposing the title of a
different Guidelines document. Note that, since the form lacks an explicit Submit mechanism, and is
therefore intrinsically dependent on scripting, you may not be able to
use it to fetch the selected Guidelines document.
In order to conform to checkpoint 5.4,
your user agent must offer a configuration that prompts you to
confirm the submission of any form if submission of the form's content
is initiated by anything other than an explicit user request.
Conformance with this checkpoint would prevent the automatic
submission of the form when the selected OPTION changes,
even if your user agent does not satisfy checkpoints 9.4 and 9.5.
In order to conform to checkpoint 9.5, your user agent must offer a configuration in
which you are able to establish focus on any element for which
an input device event handler has been explicitly associated
without automatically triggering that event.
As regards this test page, this means that you are able to
establish focus on the SELECT OPTION form control
for which an onchange event has been defined
without having the onchange event
fire when the default value assigned to the form control changes.
In order to conform to checkpoint 9.4, your user agent must allow you to query the form control, once it receives focus, for a complete list of the input device event handlers which have been explicitly associated with it.
Please send comments and observations about this test page to <w3c-wai-ua@w3.org>. Your comments will be archived in the User Agent mailing list's public hypertext archive. Please make your observations as specific and detailed as possible. Be sure to include the following information when you report your observations to the User Agent Accessibility Guidelines Working Group: