多语言网站可访问性及其重要性的重要提示!

By: 天网科技美国有限责任公司
8 mins
500
多语言网站的可访问性

在多个地区经营的企业, 他们的目标受众在很多方面都不同,其中一个深刻的方面是语言.

达到不同的受众,迎合他们的预期体验, 网站必须用当地方言与他们交流. 这就是为什么一些组织开始制作多语言网站的原因.

这些网站为用户提供用他们喜欢的语言浏览信息的服务. 然而,没有机会跳过可访问性. 就像网站创建的其他重要方面一样,比如平台, domain name, hosting, 网站的类型, multiple language website accessibility is also among those facets that no organization is supposed to evade.

让我们看看如何制作一个可访问的多语言网站.

多语言网站可访问性的重要性

英语是世界各地网站创建的事实上的语言之一. 但也有用户不懂英语,只能理解一些特定的语言. 如果这些用户依赖屏幕阅读器来浏览你的网站, 如果他们的屏幕阅读器用英语阅读内容会发生什么? 你也可以查看我们的完整文章 屏幕阅读器可访问性.

Thus, website language should be comprehensive for everyone and their assistive technologies as well.

WCAG多语言网站可访问性标准

Web content accessibility guidelines (WCAG) have defined rules for multiple-language websites in order to help them achieve accessibility. It says the language used on each page of a website including phrases must be programmatically accessible by assistive software such as screen readers.

It means the HTML code of the website must specify the language attribute to make it comprehensive for assistive tools. 例如,如果一个页面是用英语编写的,那么它的HTML将看起来像这样

如果网页上有一些用另一种语言写的短语,比如说法语, 这个短语应该有适当的语言属性.

WCAG’s conformance level AAA also has some additional criteria to make accessible multiple language websites, such as:

  • There should be some way to understand unfamiliar words like jargon, idioms, and abbreviations.
  • A simpler text summary with illustrations is recommended to make complex content easy to understand for users with cognitive disorders.
  • 单词的上下文必须在句子中清晰,才能理解它的确切含义. For example, 如果一个单词的过去时和现在时发音相同, 网站必须在特定的句子中识别单词的正确发音.

您可能还会喜欢: Wcag aa vs aaa

建立无障碍的多语言网站

Drupal 10有什么新功能

 

  1. 语言编码

    如上所述, 这是网站应该关注的第一件事, 纠正每个页面代码,使语言在页面代码中得到识别. 辅助技术,如屏幕阅读器,盲文设备等. 不能通过阅读文本来理解网站的语言. 相反,他们阅读代码,然后识别网页上的语言.

    只要这些工具识别出语言, 软件会调整语速, pitch, 根据语言的口音. 现在,有一些现代的屏幕阅读器,比如Jaws和Window Eyes. 这些屏幕阅读器可以讲多种语言,发音精确.

    通过设置' lang '属性,如上所示设置语言代码.

    如果忘记提供主语言代码, there are chances that screen readers will start reading the content in its default set language. For example, 如果屏幕阅读器的默认语言是英语,内容也是用英语编写的, 这样对用户来说就不是问题了.

    However, 如果您提供了错误的语言代码, for instance, 如果网页是用英语编写的,并且你已经将' lang '属性设置为法语, 这将是一个问题. Because screen readers will read English content in French and users will not be able to understand anything.

    Moreover, 如果你的网站内容是用多种语言写的, 根据Web内容可访问性指南, the human language of every passage and phrase in the written content should be programmatically determined other than proper names, 技术术语, 不确定语言的词, 以及已经成为该特定地区语言一部分的单词.

    Set the phrases or words that are different from the primary language by setting the ‘lang’ attribute for them as well.

  2. 语言方向

    它是多语言网站的一个重要方面. 如果你的网站的语言是从右到左而不是从左到右写的, 确保在页面代码中指定文本的方向. 为此,您需要在网站的HTML部分设置' dir '属性.

    Languages like Urdu, Persian, and Arabic are being written from the right-to-left (rtl) direction. So, 设置dir属性 对于这些语言:

     

    Please note, ' dir '属性不需要指定从左到右的语言(例如, 因为它是默认的文本方向.

    RTL language pages require to have different layouts because they are supposed to be aligned right side and not on the left side. 这意味着页面布局必须适应rtl语言.

    Example – The United Nations website is created in such a way that its layout has adapted to the Arabic language for the whole setting in right-to-left and the website’s English version has an exactly reversed layout.

  3. Links

    There are chances that your website and some of the external links have different languages. In that case, you need to provide proper information for assistive technologies so that users who will use these tools, 也能阅读这些链接吗.

    这可以通过使用' hreflang '属性来实现. This attribute helps you to let screen readers know the primary language and language of the links on the page. And then, screen readers pass on the same information to the users who are using those web pages.

  4. Font sizes

    不同的语言需要不同的字体大小. 用户无法读取相同大小的每种语言字体. For example, Chinese, Arabic, 和日语在和英语一样大的字体下读起来有点困难, French, 和德语. So, web pages are expected to have font size according to the language they have content in.

    为了实现这个目标, either set CSS ‘lang’ pseudo-class for different font sizes or make changes in the HTML code to specify which language and font size is used on the page.

  5. 谷歌语言识别

    Assistive technologies understand the code; however, Google doesn’t recognize the language code. 谷歌使用自己的技术来读取网页的语言. 事实就是如此 谷歌建议 每页不要使用一种以上的语言.

  6. Words’ length

    每种语言都有自己的本质和单词长度. 在某些语言中,句子可以用更小的空间书写, 然而,同样的句子在其他语言中可能会占用更多的空间. Thus, a multiple-language website must have a design that can cater to every language with a similar presentation.

    例如,亚马逊使其网站设计对每种语言都很灵活. The word ‘search’ has 5 characters in English, but it takes up to 10 characters in French. Similarly, ‘basket’ has 6 characters in English, and in German, it goes up to 13 characters. 亚马逊在其网站设计中巧妙地运用了一些元素, they’ve removed the wish list button from the search bar for languages with longer words like Italian and German.

    虽然这可能不是在所有情况下都可行. 因此,为了克服这些问题,您可以使用含义相似的较短的单词. 此外,在更改设计之前,请确保正确翻译内容.

  7. 编码字符

    Website content has many characters (collection of letters and symbols) that must be comprehensive for screen readers. 因此,字符编码有助于破译这些字母和符号. Ensure to use the right character encoding because there are myriad characters you use in your content and wrong encoding will confuse assistive technologies.

    大多数组织使用“Unicode”进行字符编码. 它包含几种语言的最大字符, 脚本和大多数操作系统也支持它. And thus, it is a good choice to use Unicode to encode multiple languages and scripts for multi-lingual websites.

 

Wrapping up

 

建立多语言网站不是一件容易的事. 就像网站的其他方面一样, focusing on each language translation and ensuring that the website is accessible in every language is what an organization is expected to do.

 

如果有任何困惑,请聘请一位 网站开发机构 拥有一个可访问的多语言网站是一个好的选择吗.

 

As an associate member of International Association of Accessibility Professionals (IAAP), pg电子官网是全球无障碍社区的一部分. 我们也是W3C的正式成员.

 

Skynet Technologies is a one-stop solution to build an accessible multi-language for UI/UX web design, ADA网页无障碍服务, and 数字营销服务 在同一屋檐下. 创建一个可访问的多语言网站,在全球范围内发展您的业务. 我们还开发了一个 All In One无障碍PRO widget which will make your website compliance up to 40% and available in multiple language. 填写下面的表格请求免费报价或发送邮件到 (电子邮件保护) 了解更多信息.

 

407