为了确保表单正确地显示这些信息,应该将表单进行本地化以适合当地的语言环境(国家和语言)。
To ensure that your form displays this information correctly, you should localize your forms to suit the locale (country and language) in which they will be used.
文本消息、数值和日期都可以用对语言环境敏感的方式进行显示,还可以将时间调整到特定的时区。
Text messages, numerical values, and dates can all be displayed in a locale-sensitive manner, while times can also be adjusted for specific time zones.
翻译的环境是双语环境;源语言段和该段的翻译在单独的编辑器屏幕中并排显示。
The translation environment is bilingual; source language segments and the segment translations are displayed side by side in a single editor screen.
每次添加或更改字符串时,都应当重新生成消息文件,否则将在目标语言环境显示未翻译的新文本。
Every time strings are added or changed, the message file should be regenerated, or the new text will appear untranslated in the target locales.
最佳方法是为数据选择一种中立的表示,显示给特定语言环境的用户时再进行适当的格式化。
The best strategy is to choose a neutral representation for your data and format it as appropriate when you display it to a user in a specific locale.
然后,如果应用程序尝试显示无效的语言环境,则要始终保证一些合理的应用程序行为。
Then, if the application tries to render an invalid locale, some reasonable application behavior could always be guaranteed.
它很好地表述了您的意图。在一些语言环境,其中的文本可能以斜体显示,而在另一些语言环境下则可用下划线或者引号来强调。
This is a nice and general expression of your intent, which in some locales might result in the contained text being rendered in italics and in others might result in underlined text or quoted text.
图8显示了指定法语的语言环境的输出。
Figure 8 shows the output for a locale specifying the French language.
图7显示了当浏览器首选项为英语语言环境时的结果。
Figure 7 shows the results when the browser preferences reflect an English-language locale.
在大多数情况下,您必须为一种语言环境正确设定日期和货币的格式并正确显示日期和货币。
In most cases, you must properly format and display dates and currency for a locale.
此外,为datestyle属性指定了一个full值,这样一来所有的日期字段就将用一种特定于语言环境的格式进行显示。
In addition, a value of full is specified for the dateStyle attribute, so that all date fields will be displayed in a locale-specific format.
清单4显示如何在Out putData数据结构中设置对语言环境敏感的输出。
Listing 4 shows how to set locale sensitive output in the OutputData data structure.
由于此验证消息应该被本地化,因而验证逻辑需要使用之前准备好的Ajax实用程序来针对各类有效性问题显示特定于本地语言环境的消息。
Because the validation message should be localized, the validation logic should use the Ajax utility prepared before to get locale-specific messages displayed for each type of validity issues.
清单3显示如何在InputData数据结构中设置请求语言环境。
Listing 3 shows how to set request the locale in the InputData data structure.
假设您有一个包含问候消息“hello”的页面,并且需要根据具体的语言环境(例如,zh_CN 表示中国)显示“hello”的不同译文。
Suppose you have a page that contains the greeting message "hello" and need to show different translations of "hello" based on the specific locale (for example, zh_CN for China). The target HTML is
当您显示有关跨洲语言环境(比如澳大利亚英语)的时间信息时,针对用户时区定制数据与对其进行正确格式化一样重要。
When you display time-of-day information for a continent-spanning locale such as Australian English, customizing the data for a user's time zone is just as important as formatting it properly.
固定本地化多语言环境中显示。
固定本地化多语言环境中显示。
应用推荐