Documentation Center

Configuring Publication-Specific CSS

Adding CSS styles to a skin allows you to set the global appearance of the application. In the case where specific publications need specific styling, you can configure a specific CSS file to be loaded for a given publication, language version, or group of publications.

About this task

Extending CSS style rules allows you to change the style and display of XHTML elements and images on the screen. Common modifications are changing font sizes, colors, and background images, and making changes to padding or margins.

Procedure

  1. Create a new CSS file that contains the modifications specific to your publication or group of publications in ContentDelivery_home/db/LiveContent/ui/skins/your_skin/css.

    For example, create red_publication.css

  2. Upload the new skin customization into the database.
    • You can upload the resources using the web UI, as described by Adding a Skin and Resources.
    • You can also update the skins via the command line using the loaddb tool. Copy the updated skin resources from the source code repository to ContentDelivery_home/db/LiveContent/ui/skins/<your_skin>/.
      • On Windows, to load the most recent changes into the database run this command:

        loaddb.bat UPGRADE

      • On Linux, run this command:

        loaddb.sh UPGRADE

  3. Modify the publication configuration for each publication or language variant that should use the new CSS file by adding a pub.css configuration item referring to the new CSS file.

    For example, you might create a publication configuration item specifying pub.css="red_publication.css".