User's Manual

Presenting Data following User's Locale Convention
Beta Draft Building Global Applications 8-5
This setting does not imply any conversion of outgoing pages. Your application must
ensure the server generated pages are encoded in UTF-8.
Organizing the Content of HTML Pages for Translation
Making the user interface available in the user's local language is one of the
fundamental task in globalizing an application. Translatable sources for the content of
an HTML page belong to the following categories:
Q Text strings hard-coded in the application code
Q Static HTML files, images files, and template files such as CSS
Q Dynamic data stored in the database
Strings in PHP
You should externalize translatable strings within your PHP application logic, so that
the text can be easily available for translation. These text messages can be stored in flat
files or database tables depending on the type and the volume of the data being
translated.
Static Files
Static files such as HTML and GIF files are readily translatable. When these files are
translated, they should be translated into the corresponding language with UTF8 as
the file encoding. To differentiate the languages of the translated files, the static files of
different languages can be staged in different directories or with different file names.
Data from the Database
Dynamic information such as product names and product descriptions are most likely
stored in the database. In order to differentiate various translations, the database
schema holding these information should include a column to indicate the language of
the information. To select the translated information, you need to include the WHERE
clause in your query to select the information in the desired language of the query.
Presenting Data following User's Locale Convention
Data in the application needs to be presented in a way that conforms to the user's
expectation, if not, the meaning of the data can sometimes be mis-interpreted. For
example, the date '12/11/05' implies '11th December 2005' in the United States,
whereas in the United Kingdom it means '12th November 2005'. Similar confusion
exists for number and monetary formats, the symbol dot '.' is a decimal separator in
the United States, in Germany this symbol is recognized as a thousand separator.
Different languages have their own sorting rules, some languages are collated
according to the letter sequence in the alphabet, some according to the number of
stroke counts in the letter, and there are some languages which are ordered by the
pronunciation of the words. Presenting data not sorted in the linguistic sequence that
your users are accustomed to can make searching for information difficult and time
consuming.
Oracle Database Express offers many features that help to refine the presentation of
data when the user's locale preference is known. Here are some examples of locale
sensitive operations in SQL.