W3C home > Mailing lists > Public > w3c-wai-gl@w3.org > July to September 2004

Re: [techs] Re: collapsible hierarchical menu navigation javascript (accessible)

From: James Craig <wai-wg@cookiecrook.com>
Date: Tue, 06 Jul 2004 15:47:16 -0500
Message-ID: <40EB0FD4.4080700@cookiecrook.com>
To: w3c-wai-gl@w3.org

Fentress, Robert wrote:

>>Even so, I'm not sure 
>>about your choice to use input elements as list expanders. I would 
>>probably recommend anchors.
> I did originally use anchors, but changed to image <input> because it
> allows keyboard access to onclick().  Behaviors attached to anchors do
> not (at least not consistently).

Let me expand on that a bit more. Using inputs indicates to screen 
readers that the user is in a form and that form input is expected. This 
is the same reason you should not use a text area to display scrolling 
"terms of use" text. You also have no alt, title, or label on those 
inputs. How does a screen reader user know what their clicks are 
supposed to do?

As for the onclick event on links, you can get consistent behavior, 
though it takes some extra work doubling up the onclick/onkeypress 
events, checking for event.keyCode, and making sure the function does 
not fire twice. Even with the extra work, I think it's a better solution 
than using a form element.


Received on Tuesday, 6 July 2004 16:47:18 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 16 January 2018 15:33:50 UTC