Skip to content
This repository has been archived by the owner on Sep 24, 2019. It is now read-only.

Test for WCAG failure F36: Automatically submitting a form and presenting new content without prior warning when the last field in the form is given a value #191

Open
hannolans opened this issue Mar 16, 2014 · 1 comment

Comments

@hannolans
Copy link
Contributor

http://www.w3.org/TR/2014/NOTE-WCAG20-TECHS-20140311/F36
Forms are frequently designed so that they submit automatically when the user has filled in all the fields, or when focus leaves the last field. There are two problems with this approach. First is that a disabled user who needs more context may move focus away from the field to the directions on how to fill in the form, or to other text, accidentally submitting the form. The other is that, with some form elements, the value of the field changes as each item is navigated with the keyboard, again accidentally submitting the form. It is better to rely on the standard form behavior of the submit button and enter key.

Example

<input type="text" name="text3" size="4" maxlength="4" onchange="form1.submit();">

Test procedure

  1. Enter data in all fields on page starting at top.
  2. Enter data in last field and exit from it (tab out of it).
  3. Check whether leaving the last field causes change of context.
@hannolans
Copy link
Contributor Author

This seems about the use of the onchange event and this is the counterpart of SCR19: Using an onchange event on a select element without causing a change of context

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants