Using Arabic as Locale

There are few steps needs to be taken care while you are working on multilingual application using ADF,

1. Make sure you have selected UTF-8 as part of contentType.

<jsp:directive.page contentType=”text/html;charset=UTF-8″/>

2. Add all supported locale in faces-context.xml->application->LocaleConfig

3. check for trinidad.xml for below properties,

<number-grouping-separator>
 #{view.locale.language=='de' ? '.' : ','}
</number-grouping-separator>

<!-- Set the decimal separator to comma for German -->
<!-- and period for all other languages -->
<decimal-separator>
 #{view.locale.language=='de' ? ',' : '.'}
</decimal-separator>

<!-- Render the page right-to-left for Arabic -->
<!-- and left-to-right for all other languages -->
<right-to-left>
 #{view.locale.language=='ar' ? 'true' : 'false'}
</right-to-left>

<formatting-locale>
 #{request.locale}
</formatting-locale>

4. Create one managed bean and add one attribute strLocale. generate getter and setter for the same. Create another method changeLocale() and assign values to strLocale variable.
5. Specify <f:view locale=#{bean’sScope.strLocale}”>

6. Make sure you have added locale specific property files to the project.

6. Call changeLocale() on some actions. and you are done.

7. Make sure you are specifying skin file in trinidad-config.xml and based on current locale switch which one has to be displayed.

Refer –

http://docs.oracle.com/cd/E16162_01/web.1112/e16181/af_global.htm

https://blogs.oracle.com/jheadstart/entry/adf_faces_setting_locale_throu

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s