homepage Welcome to WebmasterWorld Guest from 54.163.72.86
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Home / Forums Index / Code, Content, and Presentation / HTML
Forum Library, Charter, Moderators: incrediBILL

HTML Forum

    
Accesskey - browser implementation
dcrombie




msg:616017
 12:01 pm on Aug 18, 2004 (gmt 0)

Pressing an access key assigned to an element gives focus to the element. The action that occurs when an element receives focus depends on the element. For example, when a user activates a link defined by the A element, the user agent generally follows the link. -- W3C

In Safari(Mac) pressing Ctrl+Accesskey causes the browser to follow the link. In MSIE5(Win) it only gives focus to the anchor. Can anyone tell me what happens in MSIE6 or other Win browsers?

FYI - here are the results for the major Mac browsers:

Camino(Mac) - no affect
Firefox(Mac) - follows link
MSIE(Mac) - follows link
Mozilla(Mac) - follows link
Netscape(Mac) - follows link
Opera(Mac) - not sure what it's doing

TIA ;)

 

Lance




msg:616018
 12:17 pm on Aug 18, 2004 (gmt 0)

IE6 just sets focus to the link. It does not traverse it.

dcrombie




msg:616019
 12:51 pm on Aug 18, 2004 (gmt 0)

Bugger! I'm trying to think of a work-around using onFocus() but that would probably incur penalties from search engines (not that the link goes anywhere - just to a login prompt).

Lance




msg:616020
 1:08 pm on Aug 18, 2004 (gmt 0)

This is just a SWAG, but would it be possible to capture the key-stroke combo instead of using accesskey?

R1chard




msg:616021
 8:01 pm on Aug 19, 2004 (gmt 0)

The accesskey is supposed to "activate" the element. For a link, I interpret that to mean follow. If it was just to highlight, you'd use tab instead.

It looks like IE-Win gets it wrong with links. However, IE-Win does activate Buttons when you press the accesskey, so it's a little inconsistent.

I believe Mozilla, Amaya, Opera, iCab, Omniweb and Konq all follow the link as expected. That's the key: user expectation. I don't have to press Enter after I click a link with my mouse, because that's not what I expect to happen.

Personally, I wouldn't bother with a Javascript hack. It assumes too much about the user. You can't go changing all your pages just in case somebody is using IE, especially if it's to the detrement of everybody else. If the user has a browser that actually ignores standards (and the customs), they'll just have to put up with the hassle.

R1chard




msg:616022
 4:25 pm on Sep 24, 2004 (gmt 0)

I've just noticed that the W3C use accesskeys for the radiobuttons on their HTML validator. And as expected, all browsers immediately check the box (rather than gove focus). So how come IE gets it right for this, but wrong for links?

Anyway, isn't it about time this forum started with accesskeys? We talk about them every so often, but how about actually using them as a working example? Even mass-market ones like vbulletin have accesskeys (S to submit, 1 for home, 4 for search, etc, as is now the standard)

fwordboy




msg:616023
 3:29 pm on Sep 25, 2004 (gmt 0)

with accesskeys it is important to note that they can damage user expectation. Because accesskeys overide keyboard shortcuts for the browser and the screenreader they can make your website much more frustrating to the people you're trying to help.

check out dive into mark's accessibility statement for good access key assignments:
[diveintomark.org ]

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / HTML
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved