我的 html 中确实有一个奇怪的错误 - 不关注带有 Tab 键按下/重复元素的导航链接
由于未知的原因,我的 html 导致所有浏览器(除了 firefox 和 ie)在使用 tab 键时跳过 nav 元素中的链接,根本不关注它们。 firefox 做了一些同样奇怪但不同的事情,它不会跳过链接,而是复制标题链接并将 h1 元素放在标题内的链接之外。使用 ie 它可以完美工作...是的,我知道...(哇!)
我已经将其范围缩小到我的 html 中的问题,因为它仍然在禁用 javascript 和 css 的情况下发生。我还没有包含跳到主要内容链接,所以不可能是这样,我没有在任何地方使用 tabindex 属性,并且所有这些都验证得很好。
这是您自己查看的问题 - www.thisbengreenguy.com/creative.php
感谢您的所有提前提供帮助。
for reasons unknown my html is causing all browsers, except firefox and ie, to skip over the links in the nav element when using the tab key, doesn't focus on them at all. firefox does something equally bizarre but different, it doesn't skip the links, instead it duplicates the header link and places the h1 element out of the link within the header. and with ie it works spot on perfect... yeah i know... (woah!)
i've narrowed it down to being a problem within my html because it still happens with both javascript and css disabled. i haven't yet included a skip to main content link so it can't be that, i haven't used the tabindex attribute anywhere and it all validates perfectly fine.
here's the problem to see for yourselves - www.thisbengreenguy.com/creative.php
thanks for all your help in advance.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
通过将其从 html 5 向后转换为 xhtml strict,我让它在 Firefox 中看起来正确,并且现在在 Opera 和 IE 中完美工作。在 safari 和 chrome 中,您必须使用 opt/alt + tab 来聚焦。至少它看起来像预期的那样,并且是我能得到的最接近完全可访问的。
by converting it backwards from html 5 to xhtml strict i've got it looking right in firefox and working perfectly in opera as well as ie now. and with safari and chrome you have to use opt/alt + tab to focus. at least it looks as intended and is as close to completely accessible as i can get it.