Copy the dynamic resources for the theme
Make a unique copy of the dynamic resources for the theme. Make sure that Eclipse, IBM Rational Application Developer, or Rational Team Concert with the Java EE developer tools add-on is installed.
- Switch to the Java EE perspective, and select...
File | New | Dynamic Web Project
- In the Project name field, enter the name of the theme, such as CustomTheme.
- If it is not already selected, select 2.4 for the Dynamic Web Module version.
- Select Add project to an EAR and click Next to the Web Module page.
- On the Web Module page, change Context Root to myTheme, or whatever we want the context root to be, and click Finish.
- Expand the new CustomTheme project and find and expand the WebContent folder.
- Find the folder...
PORTAL_HOME\theme\wp.theme.themes\default85\installedApps\DefaultTheme85.ear\DefaultTheme85.war\skins
...and drag it onto the WebContent folder. This step copies and imports the skins folder into the dynamic web project.
- Find the folder...
PORTAL_HOME\theme\wp.theme.themes\default85\installedApps\DefaultTheme85.ear\DefaultTheme85.war\themes
...and drag it onto the WebContent folder. This step copies and imports the themes folder into the dynamic web project.
- In the CustomTheme project, find the WEB-INF folder inside the WebContent folder.
- Find the file...
PORTAL_HOME\theme\wp.theme.themes\default85\installedApps\DefaultTheme85.ear\DefaultTheme85.war\WEB-INF\decorations.xml
...and drag it onto the WEB-INF folder. This step copies and imports the file into the dynamic web project.
- Find the folder...
PORTAL_HOME\theme\wp.theme.themes\default85\installedApps\DefaultTheme85.ear\DefaultTheme85.war\WEB-INF\tld
...and drag it onto the WEB-INF folder. This step copies and imports the tld folder into the dynamic web project.
- If we are developing a theme for a production portal, copy the following plugin.xml file into the dynamic resources. Find the file...
PORTAL_HOME\theme\wp.theme.themes\default85\installedApps\DefaultTheme85.ear\DefaultTheme85.war\WEB-INF\plugin.xml
...and drag it onto the WEB-INF folder. This step copies and imports the file into the dynamic web project.
- The previous files and folders are the only ones that we need. Do not copy any others from the DefaultTheme85.war file.
- Modify dynamic resource references for our new theme
- Find the CustomThemeEAR project, right-click it and select...
Export | EAR file
- Click Browse, select a folder to export the EAR file to.
- Click Save and click Finish.
- Log on to the WAS console and go to...
Applications | Application Types | WebSphere enterprise applications | Install toolbar button | Browse... myfile.ear | Next | Fast Path | Generate Default Bindings | Next
- Change any installation option values that we want, or use the default values, and click Next.
- For Map Modules to Servers, select the Custom Theme module in the table. Then, select the ...,server=WebSphere_Portal entry in the list, click Apply, and click Next.
- Click Finish.
- When the EAR file is done installing, click Save directly to the master configuration.
- Check the CustomTheme EAR in the table of enterprise applications and click the Start toolbar button.
- On the file system, find and expand the WP_PROFILE\installedApps\<cell>\myTheme.ear\myTheme.war folder. The unique copies of the dynamic resources for the theme are in the themes and skins folders. When customizing the theme, always change the files at that location and do not modify the ThemeModules.war file.
Parent Create a copy of the themeRelated tasks:
Modify the dynamic resource references for the theme