WebAIM - Web Accessibility In Mind

E-mail List Archives

Re: WebAIM-Forum Digest, Vol 25, Issue 12

for

From: Joel Hickman
Date: Apr 19, 2007 3:10PM


I think that the problem is that most screen readers (that I know of) rely
on technology that is rapidly becoming obsolete. They depend upon parsing
the source of the page (that arrives as the http response from the server)
rather than attempting to dynamically navigate the DOM which may be modified
via DHTML. This means dynamic modifications within a page performed by the
client (browser) are not picked up.

Assuming you can require Javascript (not usually a valid assumption) then I
believe that a dynamic solution that causes a new window to pop up may be
visible to the screen reader. The easiest to use would probably be the
Javascript alert function. Here is an example embedded in a button:

<button name='alrt' value='Send Alert' style='button' onclick="alert('This
is an error message.')">Send Alert</button>

Now, in a real application, you would probably use some other event such as
onchange rather than onclick, and rather than calling alert directly, you
would call a function that performed error checking and called alert if an
error was found.

A discussion on the accessibility of alert:

http://www.webaim.org/discussion/mail_message.php?id=1072

Joel