WebAIM - Web Accessibility In Mind

E-mail List Archives

RE: JavaScript alerts


From: Paul Bohman
Date: Sep 9, 2002 4:33PM

As a general observation, server-side validation is safer than
client-side, mainly due to the fact that people can turn JavaScript off
and possibly spoof the validator. That's a separate issue from
disability access, but it may be reason enough to say that server-side
validation is better.

As far as disability access is concerned, there are a few potential
hazards of popup windows, but I have to say that I don't consider all of
them to be accessibility "barriers". Here are some scenarios:

Someone with low vision will enlarge the screen so that they are only
looking at a small portion of the available screen space. When a popup
window occurs, it may appear in an area that the screen enlarger is not
enlarging, thus confusing the person because the popup is not visible.
However, the default behavior of most screen enlargers is to move the
visual focus to the area of the screen that receives the programming
focus, so it is likely that the screen enlarger will jump to the
location of the popup window. Most will do this, but not all.

Someone with a cognitive disability may or may not know why an error
message popped up and may or may not know how to deal with it.

Someone using a screen reader will likely hear the contents of the popup
window being read out loud, so the popup will be accessible as long as
JavaScript is turned on and as long as the screen reader supports
JavaScript popup windows. Most of them do.

What it boils down to is this:
Popup windows are an accessibility problem for those with JavaScript
turned off or with software that doesn't support JavaScript, regardless
of disability. Most people do not fall into this category (see note
below). For everyone else, it becomes more of a usability concern than
an accessibility concern. Will users understand the popup? Will they
know what to do with it? Is the text worded well? These are the types of
questions that need to be asked.

So, to come back to my original statement, I would say that server-side
validation is better, but not strictly for reasons of disability access.

Note: Even though most people do not fall into this category (of
JavaScript not being available), it is unwise to design only for the
majority. After all, the whole idea of accessibility is to provide
information to the maximum amount of people. Some people use screen
readers or other technologies that do not support JavaScript, or that
support it unreliably.

Paul Bohman
Technology Coordinator
WebAIM (Web Accessibility in Mind)
Center for Persons with Disabilities
Utah State University

-----Original Message-----
From: Steve Vosloo [mailto: <EMAIL REMOVED> ]
Sent: Monday, September 09, 2002 1:52 AM
Subject: JavaScript alerts

I have form that uses JavaScript to perform client-side validation, i.e.
when the user hits submit without filling in the first name an alert box
pops up. Is this bad accessibility? Should I use server-side validation
to avoid popups that change the user focus?


Steve Vosloo
Division Manager
Usability Junction

Tel: + 27 (0) 21 409 7961
Fax: + 27 (0) 21 409 7050
Cell: + 27 (0) 83 463 0012
Web: www.usabilityjunction.com

To subscribe, unsubscribe, or view list archives,
visit http://www.webaim.org/discussion/