开发者

Tab Skips Select Form Fields in Mac Firefox. Can I stop this behavior by changing my program?

Tab skips select form fields in Mac Firefox.

http://www.tonyspencer.com/2006/05/02/tab-skips-select-form-fields-in-mac-browsers/

talks about the issue, and shows how to stop it by changing the system preference.

However, I am running some online psych ex开发者_运维百科periment and would like to avoid asking users to change their system preference. So I need some way to stop skipping-behavior in my code.

Is it possible? Any ideas appreciated.

Thanks in advance.

=====edit========

Please note that I cannot use JQuery in my code, but I can use JavaScript.


I solved the issue by myself. What I did was not very optimal, but here is what I did.

  1. assign tabindex for each element which will have focus.
  2. when enter key is pressed (tab caused another issue, so I didn't use it), search the element whose tabindex = 1 + currentelement.tabindex, and make it as next element.
  3. set focus to the next element.

Thanks.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜