+

Search Tips   |   Advanced Search

Themes - Development and operations

To develop themes for a production portal...

  1. Develop the theme components
  2. Package theme
  3. Deployment to systems

The package is either created as the result of a build process that takes the code from a version control system and creates the correct artifacts, or the artifacts are created by developers. Multiple artifacts create a release we can deploy to portal.

Components of a portal theme include:

    Static content
    Similar to the content of a static website. The markup is defined by HTML files. Includes the CSS and JavaScript files used by the themes.

      theme.html

      Markup identical for all the pages this theme is applied to.

      layout.html

      Decoration of the content area. Can be different between pages.

      skin.html

      Decoration of the individual portlets on the page.

    If the files used by the theme are not part of the theme folder, and therefore not part of the theme structure, then those files are named external. External files are shared by multiple themes.

    Dynamic content

    Generated based on the data model of WebSphere Portal with technologies such as JavaServer Pages or Java code.

    Runtime Configuration

    Scripts are used to register the theme and skins with WebSphere Portal. Runtime Configuration components are server configurations, similar to Resource Environment Provider settings, required for the themes and skins to work correctly.


Develop Theme Components

There are several ways to develop a custom theme. One easy way is to make a copy of a ready-to-use theme.

    Develop within an IDE

    1. Set up a project
    2. Add artifacts like HTML, CSS, and JavaScript files
    3. Export the project
    4. Deploy project to server, either as a compressed file in the file store, or as an EAR file.
    5. Register the theme with theme.xml file

    Develop on the live server using WebDAV

    1. Log on to WebDAV entry point to file store
    2. Copy a ready-to-use theme, or create a folder to start from scratch.
    3. Add your HTML, CSS, and JavaScript files
    4. Export these files to create the theme component package


Package theme components

We can combine all static files for all themes and all external files shared between themes into one installable artifact, or we can split the files into multiple artifacts. All packages must contain an XML Access script to deploy the theme, and a list of runtime configurations to be applied to the server.

  • If we only created static resources, but used dynamic spots...

    • Create a package containing a compressed file containing the static resources to be deployed to the file store.
    • Create a package containing an EAR file containing a WAR file with the static resources to be deployed to the application server.

  • If we created custom dynamic spots, like components based on JSP technology, to be packaged with the theme...

    • Create a package containing a compressed file containing the static resources to be deployed to the file store, and an EAR file containing a WAR file containing the dynamic resources.
    • Create a package containing an EAR file containing one WAR file with the static resources, and a second WAR file containing the dynamic resources. This file can be deployed to the application server.

We can also package the artifacts created in a Portal Application Archive (PAA) file for the Solution Installer. The Solution Installer automatically performs the steps to deploy the artifacts.


Deploy theme components

How the theme components were packaged determines the method used to deploy themes. All options require an xmlaccess.sh script and runtime configuration options or a PAA file.

      Compressed file without EAR file
      Use web-dav-deploy-zip-command to deploy the compressed file and use the xmlaccess command to run the script. Use the WAS console to add the runtime configuration.

      Compressed file with EAR file
      Use web-dav-deploy-zip-command to deploy the compressed file. Use the WAS console or scripts to deploy the EAR file. Use the xmlaccess command to run the script.

      An EAR file with no compressed file
      Use the WAS console or scripts to deploy the EAR file, and use the xmlaccess command to run the script.

      PAA file
      The Solution Installer automatically detects the steps to perform deployment.


Parent Develop themes for a production portal

Related concepts:

Export content from the filestore
Install add-ons