14

随着越来越多的人使用 Backbone、Ember 和其他 JS MVC 类型的框架,越来越多的 HTML DOM 正在动态构建,第一个 HTML 页面仅包含一个“根”元素,用于将生成的 HTML 转储到其中。

这种做法是508投诉吗?

4

3 回答 3

3

大概只要每个人都有办法访问您提供的任何信息,那么可以。如果您完全依赖 JavaScript 来提供上述信息,那么我猜不会,因为不是每个人都启用了 JavaScript。第 508 节要求<noscript>标签提供通过其他方式获取信息的能力,因为并非所有辅助技术都可以访问相同的信息。这似乎是这些事情的一般工作方式(W3 可访问性指南强调了这一点,而 508 标准,特别是那些关于equivalency的标准,似乎说得差不多)。

因此,根据508 标准,呈现不必相同,只要体验是“可比的”即可。但我认为,如果演示文稿依赖于 JavaScript(并且动态 DOM 构建需要JavaScript),则体验将无法比较,因此您将不得不提供该站点的替代 HTML 版本。

于 2012-11-30T01:17:07.957 回答
3

这一切都取决于你如何做到这一点。我可以采用一个本应符合 508 标准的系统(如 Plone)并使其完全不符合标准。

如果您想制作动态网站,我建议您研究 WAI-ARIA。它是官方 HTML5 规范的一部分,并受到所有主流浏览器的支持。

简而言之,WAI-ARIA 的工作原理是允许开发人员向标签添加角色属性。例如,如果标签会在页面上弹出,您可以赋予标签“警报”角色。您可以将角色与 CSS 和 JS 结合起来,创建可供各种残障人士使用的应用程序。

于 2012-12-02T20:59:27.070 回答
1

I believe, so long as you provide a static version of your webpage, then it should be complaint. MVC and MVVC websites contain AJAX content and, by default, they use JavaScript to push and pull the information on the page as well as construct the DOM. This alone isn't enough, but If you follow the guidelines for providing an indexed version of your website then you can have a full static representation of each page. Those pages are pages that you would want a search engine to see (this would essentially be the same as the public). Follow this approach and theoretically it should work.

Here's some more info about how this works with a MVC JavaScript framework called AngularJS: http://www.yearofmoo.com/2012/11/angularjs-and-seo.html

于 2012-11-30T01:45:59.080 回答