11.4.2 IBM styles
WebSphere portal provided a large list of classes for use within portlets, too numerous to list here. Once again, it is recommended that you use the WSRP style when available.
The Style.css will be located in was_root/installedApps/hostname/wps.ear/wps.war/themes/html. In this Style.css you will be able to find both IBM and WSRP styles and a description about the style. WebSphere portlet also provides a HelpStyle.css to provide a constant look and feel to the Help mode of portlets.
During aggregation, the most specific directory is searched first. If a match is not found there then the search gets more general until a match is found. This allows the creation of style for different scenarios. Example 11-14 shows the order of the search.
Example 11-14 Order of precedence during aggregation
1.
|
|
| locale_region
|
2.
|
|
| locale
|
3.
|
|
| client
|
4.
|
|
| theme_name
|
5.
|
|
| markup
|
For example, if you use a style that behaves differently in Internet Explorer, you could change that Style under the ie directory while leaving the style in the directory below untouched. Now when an Internet Explorer client access the page they will see the correct style.
Let's say we are using the Science theme and need to create a new class and a special value for clients using Internet Explorer. We could update the class under the ie directory.
WebSphere portlat will search the following directories for the styles. You would need to update the Style.css in the most specific directory under ie in order to see the changes for Internet Explorer. All other browser will pick up the Style.css from the most specific directory not containing ie.
|
|
| themes/html/Science/ie/en/en_US/Style.css
|
|
|
| themes/html/Science/ie/en/Style.css
|
|
|
| themes/html/Science/ie/Style.css
|
|
|
| themes/html/Science/Style.css
|
|
|
| themes/html/ie/en/en_US/Style.css
|
|
|
| themes/html/ie/en/Style.css
|
|
|
| themes/html/en/en_US/Style.css
|
|