Add JSPs for a new language
For the new language in the portal, we also need to add JSPs. Some JSPs containing mostly text, such as help JSPs, are translated directly which means the text is contained in the JSP and not in a resource bundle. For JSPs that do not use resource bundles, we need to copy and translate an existing JSP and store it in the appropriate location.
The location of JSPs can be, for example, jsp/[mime-type]/[language]/[country]/[variant]/files.jsp. For instance, existing help JSPs are already translated in WebSphere Portal and placed in the relevant [language]and [country] subdirectories. When deciding where to store new JSPs, we need to consider how the portal locates a JSP for rendering its content.
The following is an example of the order in which directories are searched, where path1 is a user-defined path, ie5 is the markup version (here: Internet Explorer 5), and the locale is en_US:
- /html/path1/ie5/en_US/mytemplate.jsp
- /html/path1/ie5/en/mytemplate.jsp
- /html/path1/ie5/mytemplate.jsp
- /html/path1/en_US/mytemplate.jsp
- /html/path1/en/mytemplate.jsp
- /html/path1/mytemplate.jsp
- /html/en_US/mytemplate.jsp
- /html/en/mytemplate.jsp
- /html/mytemplate.jsp
- /mytemplate.jsp
This search order means that if the user language is not supported, the portal will choose the file in the locale independent location, which in the example is the English file.
Parent Support a new language