Xlates
Livelink uses Xlates to facilitate the internationalization of its interface into other languages. Using Xlates, you can translate:
Each OSpace has an XDB file for each language into which it is translated. For example, for the Projects OSpace, project.oll there is a corresponding XDB file for the English language, called projectUSA.xdb, for French called projectFRN.xdb, and so on.
An XDB file stores the information required to translate each string of user text in its OSpace and corresponding HTML files. For each string, the XDB stores:
This set of information forms an Xlate. XDB stands for Xlate DataBase. Xlates are organized into groups for easier management, and the groups in an XDB are given names that become part of the Xlate's key.
For a more complete discussion of internationalizing Livelink, including the format for XDB files, see the Builder Developer's Guide.
Referencing Xlate String Constants
To allow for easy internationalization, you can convert all displayable Strings in your custom OSpaces into Xlates. These are stored in your OSpace's XDB file, which can be exported, translated into the destination language, and reimported into Livelink Builder.
By referencing an Xlate instead of the string itself, you can easily create versions of Livelink for different languages without having to make modifications to your code. Xlates should be used in your code instead of text, when displaying messages or prompts.
For example, the following code contains Strings that should be changed to Xlates:
function Assoc Execute() String scriptName = request.SCRIPT_NAME assoc section_1 = ._NewSection() string imagePrefix = \ $Kernel.ModuleSubsystem.getrefitem(this).supportprefix() section_1.anchorHREF = scriptname +"?func=Personal.Suggestions" section_1.heading = "Personal Suggestions Area" section_1.imageURL = imagePrefix +"icon_suggestionbox.gif" section_1.imageALT = "Personal Suggestions Area" sections.(section_1.heading) = section_1 end
These Strings can be changed to the following Xlates (where the Xlates are defined in the corresponding XDB file):
section_1.anchorHREF = scriptname +"?func=Personal.Suggestions" section_1.heading = [Suggestions_HTMLLabel.PersonalSuggestionsArea] section_1.imageURL = imagePrefix +"icon_suggestionbox.gif" section_1.imageALT = [Suggestions_HTMLLabel.PersonalSuggestionsArea]