2.02.02.a Select menus: Answer
Question 2
Correct answers: 1 and 4
Which of the following are accessible alternatives to using onChange with form menus for navigation? (Choose all that apply)
-
Provide a submit button then use server-side scripting to redirect the browser based upon the menu item selected.
Server-side scripting removes the need for the JavaScript redirection. This may, however, require additional programming skills.
-
Force keyboard users to navigate to each of the available menu items in order, then return and select the next item in the list until they come to the menu item they desire.
This is the inherent problem with using onChange with menu items - the keyboard cannot be used to "browse" through the list of menu items without activating each one in order.
-
Provide a redundant list of HTML links for each of the items in the drop-down menu.
The purpose of the drop-down menu navigation is to allow multiple navigation items within a small amount of space. Providing the redundant links removes the advantage of providing the drop-down menu. Although the redundant links will be accessible, it does not solve the inaccessibility of the drop-down menu, which may be confusing to keyboard and screen reader users.
-
Allow the user to select the correct item from the menu, then provide a button adjacent to the menu which the user selects to activate the navigation script.
By removing the onChange event handler and processing the script using an accessible handler (e.g., onSubmit or onClick), the navigation element can be fully accessible.
NOTE: This approach assumes that the end user has JavaScript enabled and may not work with JavaScript disabled. For maximum accessibility, you could combine the methods of both A and D to provide both client-side and server-side processing of the navigation element.
(Content copyright Webaim) Terms of use: All documents on this Web site may be reproduced and distributed in print or electronic format only if offered at no cost to recipients and as long as full credit is given to WebAIM, including a link to the WebAIM Web site, and as long as this Terms of Use notice remains intact.