iframe 的可用性、可访问性、屏幕阅读器或任何其他开发、功能、跨浏览器问题是什么?

发布于 2024-08-20 23:21:03 字数 689 浏览 3 评论 0原文

的可用性、可访问性、屏幕阅读器或任何其他开发、功能或跨浏览器问题是什么?

有其他选择吗?

是否有任何 JavaScript/jQuery 或服务器端技术可以减少 的可用性、可访问性或屏幕阅读器问题?

为什么 W3C 没有将 纳入 XHTML Strict,而 HTML 5 支持

更新:

我在这里也发现了一些好想法: http://uxexchange.com/questions/1817/iframe-accessibility-and-usability-issues

What are the usability, accessibility, screen-reader, or any other development, functionality, or cross browser issues with <iframe>?

Is there any alternative for <iframe>?

And are there any JavaScript/jQuery or server-side techniques which can decrease the usability, accessibility, or screen-reader issues with <iframe>?

Why has the W3C not included <iframe> in XHTML Strict, while HTML 5 supports <iframe>?

update:

I found some good thoughts here also : http://uxexchange.com/questions/1817/iframe-accessibility-and-usability-issues

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

零度° 2024-08-27 23:21:03

辅助功能:

  • 滚动 iframe 比较困难,您的鼠标必须位于 iframe 的范围内。对于行动不便的人来说这很困难
  • 盲人浏览器可能不包含您 iframe 中的内容,而这些人将无法访问它。

可用性:

  • 当你有几个的时候就不太酷了
    主窗口上的滚动条
    iframe。这对于
    滚动

其他问题:

  • 移动浏览器可能不会呈现 iframe。即使渲染出来,也会显得又丑又丑。
  • 搜索引擎将很难在 iframe 中索引您的页面。他们可能会跳过它或不会正确索引
  • 加载 iframe 将比具有相同内容但没有框架的页面花费更长的时间

Accessibility:

  • It's harder to scroll you iframe , your mouse must be int the range of the iframe. It difficult with people with movement desabilities
  • Browsers for blind people may not include the content from you iframe and those people will not reach to it.

Usability:

  • It's not cool when you have several
    scroll bars on the main window and on
    the iframe. It's difficult for
    scrolling

Other issues:

  • Mobile browsers probably won't render you iframe. Even if it render it, it will look bad and ugly.
  • Search engines will have hard time indexing your pages in the iframe. Probably they will skip it or won't take indexed properly
  • Loading an iframe will take longer time than a page with the same content and no frame
薔薇婲 2024-08-27 23:21:03

为什么 W3C 不将 Iframe 纳入 XHTML 严格

因为当时它被视为广受诟病的 标签的私生子。原则上 具有许多与 相同的属性,但实际上它似乎鼓励更有品味的使用,通常避免了最糟糕的情况框架集接口遇到的导航和可用性问题。

HTML 5 支持 Iframe 吗?

(一个)。因为,与 不同, 已被证明对于混合文档(例如包含广告的文档)和许多类型的 Web 应用程序至关重要。正如其他答案中提到的,仍然存在问题,但通常 被视为保留的必要功能。 则不然,它是 HTML5 中的“不合格功能”(最接近的 HTML5 达到任何类型的“严格”)。

(b).因为 HTML5 的作者并不太关心鼓励良好的实践;它是关于记录用户代理必须做什么。他们将 HTML4 的所有过时功能以及许多其他传统但狡猾的浏览器行为(包括损坏的标签汤解析的每一个怪癖)都纳入了标准。 [旁白:我很高兴看到他们的列表中讨论的最新论点是应该如何处理 元素 - 自 HTML 2.0 的表单元素以来,实际上没有人使用过这个元素于 1995 年使其过时。]

鉴于 HTML5 的惊人大小和复杂性,他们不希望付出额外的努力来声明更有限的“严格模式”配置文件,这并不奇怪。不过,随着工作的结束,我希望看到 XHTML5 Strict 或类似的努力来减少一些混乱。就目前情况而言,Hixie 和 chums 已经对当今浏览器为实现兼容性而必须采用的每一个令人讨厌的黑客行为进行了快照,并将其作为可预见的未来所有浏览器的标准要求,从而有效地宽恕了这种不良做法。

Why W3C not included Iframe in XHTML Strict

Because at the time it was seen as a bastard child of the widely-reviled <frame> tag. In principle <iframe> has many of the same properties as <frame>, but in practice it seems to have encouraged more tasteful use, generally avoiding the worst of the navigational and usability problems that frameset interfaces suffered.

While HTML 5 is supports Iframe ?

(a). Because, unlike the <frame>, <iframe> has since turned out to be essential for mixed documents such as those including adverts, and many types of web application. There are still problems, as mentioned in other answers, but generally the <iframe> is seen as a necessary feature that is here to stay. This isn't true of <frame>, which is a “non-conforming feature” in HTML5 (the nearest HTML5 gets to any kind of ‘strict’).

(b). because the authors of HTML5 don't so much care about encouraging good practice anyway; it's about documenting what user-agents must do. They have thrown every obsolete feature of HTML4 into the standard, along with a lot of other traditional but dodgy browser behaviour including every last quirk of broken tag soup parsing. [aside: I am greatly amused to see the latest argument being discussed on their list being how the <isindex> element should be handled — an element that literally nobody has used since HTML 2.0's form elements made it obsolete in 1995.]

Given the staggering size and complexity of HTML5, it's not really surprising that they didn't want the extra effort of declaring a more limited ‘strict mode’ profile. As work comes to an end, though, I would love to see an XHTML5 Strict or similar effort to trim back some of this mess. As it stands, Hixie and chums have taken a snapshot of every nasty hack a browser has to put in for compatibility today, and made it a standard requirement for all browsers in the foreseeable future, effectively condoning the bad practice.

爱冒险 2024-08-27 23:21:03

如果您只有一个 Iframe,就不会有什么问题。然而,多个 iframe 使问题变得更加复杂。焦点不清晰,屏幕阅读器不够智能,无法找到视觉相关性(这与表格不利于设计的原因相同)。 ARIA 是解决一些类似问题的尝试。 YUI 插件链接提供了更多信息。

然而 iframe 确实在设计中找到了自己的位置。在我之前工作的一个项目中,页面包含两个 iframe(其中一个是隐藏的),隐藏的框架用于下载身份验证小程序。这不会增加任何可访问性问题,因为注意力仅限于与页面无缝合并的单个 iframe

If you have a single Iframe, there would be little issue. However, multiple iframes compound the problem. A point of focus is not clearly available and the screen readers are not intelligent enough to find visual correlation (same reason why tables are bad for design). ARIA is an attempt being made to resolve some similar issues. YUI plugin link has more information.

However iframes do find their place in design. In one project I worked before, the page contained two iframes (one of them hidden) and the hidden frame was used to download an authentication applet. This doesn't add any accessibility woes as the point of attention is limited to a single iframe which seemlessly merges with the page

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文