How to: |
WebFOCUS is a fully internationalized platform that supports the Unicode/UTF-8 standard, enabling operating systems, browsers, and applications to process and display information in virtually any spoken or written language. In addition to these default localization capabilities, users can also localize their own interface customizations. You can localize custom components in WebFOCUS in one of two ways:
Note: This option is only available for basic portals. It is deprecated in favor of the symbolic references option.
The Translations file opens. The syntax contains the identification number for every component in the portal, its name, and language reference, as shown in the following image.
<translations> <viewid value="EMBEDDED_PORTAL_1-1WEIVNL07X8" /> <translation id="EMBEDDED_PORTAL_1-1WEIVNL07X8" language="en_US" key="name" value="Embedded Portal 1"/> <translation id="VIEW-3U1SPSUGZUREZ" language="en_US" key="description" value=""/> <translation id="PAGE1-JB1X9O9F5FGX9" language="en_US" key="name" value="Page 1"/> <translation id="PAGE1-JB1X9O9F5FGX9" language="en_US" key="description" value=""/> <translation id="CONTAINER1-JT1SO4V1I13KL" language="en_US" key="name" value="Panel 1"/> <translation id="CONTAINER2-JZ156JV9OZQM7" language="en_US" key="name" value="Product Line Sales"/> <translation id="PANEL11-K41N5OL9ZDRPS" language="en_US" key="text" value="By Product"/> <translation id="PANEL8-KD1A7FGQK9F7R" language="en_US" key="text" value="Overall"/> <translation id="PANEL9-KS1UQOXUF2L3A" language="en_US" key="text" value="By Regional"/> <translation id="TITLEBAR2-L612GN2S7S1CZ" language="en_US" key="text" value="Product Line Sales"/> <translation id="TITLEBAR2-L612GN2S7S1CZ" language="en_US" key="text_base" value="Panel 2"/> <translations>
In this example, we only use English and Spanish.
The modified syntax should look similar to this:
<translations> <viewid value="EMBEDDED_PORTAL_1-1WEIVNL07X8" /> <translation id="EMBEDDED_PORTAL_1-1WEIVNL07X8" language="en_US" key="name" value="Embedded Portal 1"/> <translation id="VIEW-3U1SPSUGZUREZ" language="en_US" key="description" value=""/> <translation id="PAGE1-JB1X9O9F5FGX9" language="en_US" key="name" value="Page 1"/> <translation id="PAGE1-JB1X9O9F5FGX9" language="en_US" key="description" value=""/> <translation id="CONTAINER1-JT1SO4V1I13KL" language="en_US" key="name" value="Panel 1"/> <translation id="CONTAINER2-JZ156JV9OZQM7" language="en_US" key="name" value="Product Line Sales"/> <translation id="PANEL11-K41N5OL9ZDRPS" language="en_US" key="text" value="By Product"/> <translation id="PANEL8-KD1A7FGQK9F7R" language="en_US" key="text" value="Overall"/> <translation id="PANEL9-KS1UQOXUF2L3A" language="en_US" key="text" value="By Regional"/> <translation id="TITLEBAR2-L612GN2S7S1CZ" language="en_US" key="text" value="Product Line Sales"/> <translation id="TITLEBAR2-L612GN2S7S1CZ" language="en_US" key="text_base" value="Panel 2"/> <translation id="EMBEDDED_PORTAL_1-1WEIVNL07X8" language="es_ES" key="name" value="Portal incrustado 1"/> <translation id="VIEW-3U1SPSUGZUREZ" language="es_ES" key="description" value=""/> <translation id="PAGE1-JB1X9O9F5FGX9" language="es_ES" key="name" value=" Página 1"/> <translation id="PAGE1-JB1X9O9F5FGX9" language="es_ES" key="description" value=""/> <translation id="CONTAINER1-JT1SO4V1I13KL" language="es_ES" key="name" value="Panel 1"/> <translation id="CONTAINER2-JZ156JV9OZQM7" language="es_ES" key="name" value=" Línea de productos Ventas "/> <translation id="PANEL11-K41N5OL9ZDRPS" language="es_ES" key="text" value=" Por Producto "/> <translation id="PANEL8-KD1A7FGQK9F7R" language="es_ES" key="text" value=" En general "/> <translation id="PANEL9-KS1UQOXUF2L3A" language="es_ES" key="text" value=" Por Regional "/> <translation id="TITLEBAR2-L612GN2S7S1CZ" language="es_ES" key="text" value=" Línea de productos Ventas "/> <translation id="TITLEBAR2-L612GN2S7S1CZ" language="es_ES" key="text_base" value="Panel 2"/> <translations>
Your translation is complete.
This procedure requires a Java development tool, such as Eclipse, NetBeans, or Java Development Kit (JDK). In this example, we are using Eclipse Java EE IDE.
The New Java Project dialog box opens.
The New Java Package dialog box opens.
com.ibi.desired_name.intl.templates
where:
Is any identifiable name that you want to use for your localized data.
The New File dialog box opens.
The editor opens in the right pane.
An example of the simple symbolic reference syntax is shown in the following image.
An example of the Spanish version of the syntax is shown in the following image.
The Export wizard opens.
The JAR Export window opens.
The Save As dialog box opens.
An example of a completed JAR export window is shown in the following image.
com\ibi\desired_name\intl\templates
where:
Is any identifiable name that you want to use for your localized data.
Disk:\PROGRA~1\path to JDK\jar cvf jar-file-name.jar -C higher level directory name/ .
where:
The disk where the JDK is located.
The path to the JDK inside your Program Files directory.
The name of your JAR file. Use the same name that you used as part of the directory structure in Step a.
The name of the directory where the com folder resides.
The JAR file is created.
The following image shows an example of a completed command.
com.ibi.desired_name
where:
Is the name of your JAR file.
The following image shows the completed configuration.
For more information on creating portals, see Creating a Portal.
${value}
where:
Is the name of your symbolic reference.
An example of a symbolic reference applied in the portal is shown in the following image.
The symbolic reference value displays, as shown in the following image.
The symbolic reference value changes to its equivalent in the set language, as shown in the following image.
Note: If the Language option is disabled in your WebFOCUS environment, you can enable it in the Administration Console. Under the Dynamic Language Switch settings, select the Enable Dynamic Language check box, select the languages that you want to use in your portal from the table, and click Save.