WebAIM - Web Accessibility In Mind

E-mail List Archives

RE: Javascript Rollovers and accessibility

for

From: julian.rickards
Date: Jan 21, 2003 7:42AM


There are two forms of javascript rollovers as I have categorized them:
local and remote (my terms but I will explain them). What I call a local
rollover is where the mouse moves over an image and the image at the
position of the mouse changes to another image: for example from a red image
to a blue image. The effect is simply decorative and as long as there is no
additional information on the onMouseOver image that would be missed if
JavaScript was disabled, then this is fine. Remember, of course, to add alt
text to the image or title text to the link.

The other term I use is "remote" mouse overs and that is where moving the
mouse over one image affects another image - for example,
http://www.againsttheclock.com <http://www.againsttheclock.com>; , watch the
top graphic as you mouseOver the navbar links. In this case, the effect is
decorative too, both the top graphic and the navbar graphic. However, if you
go to http://www.mndm.gov.on.ca/mndm/mines/ims/pub/default_e.asp
<http://www.mndm.gov.on.ca/mndm/mines/ims/pub/default_e.asp>; , you will see
that the mouseover left navbar links provides additional information.
However, using the <noscript> tag, the additional information is provided to
the non-JavaScript users.

The basis of the WCAG guidelines that deal with client-side scripting is to
prevent a discrepancy of information between those people who have
JavaScript-enabled browsers and no disabilities (as defined by the audienced
affected by WCAG) and those who either have JavaScript disabled or are using
a non-JavaScript browser, those who are disabled (as defined by the WCAG) or
both. In most cases, rollovers are simply decorative and as such, they
provide no additional information and would be considered acceptable.
However, if any JavaScript does provide additional information, you must
ensure that other methods are also used to provide the information to
JavaScript-disabled users.

HTH,

Jules