Sun Java System Portal Server 7.2 Developer's Guide

Chapter 38 Customizing the Desktop User Interface

The Enterprise Sample uses Cascading Style Sheets (CSS) for the Portal Desktop presentation. The Enterprise Sample CSS files are located in the portal data directory PortalServer-DataDir/portals/portal-ID/web-src/enterprise/css.

Modify the CSS files according to your platform needs and then, redeploy the portal for the change to take affect.

Basic Customization

ProcedureTo Change the Logo

  1. Get a suitable image of the logo in the supported format (such as jpeg, gif, png).

  2. Edit the body.jsp file in the PortalServer-dataDir/portals/portal-ID/desktop/enterprise_sample/JSPTabContainerProvider/ directory.

    Look for the image file name asc-logo-8.png in the following code:


    /enterprise/images/asc-logo-8.png" alt=...

    Replace this file with your new logo file. For example,


    logo_sun_small_sdn.gif - /enterprise/images/logo_sun_small_sdn.gif" alt=...
  3. Adjust the dimensions and coordinates of the logo using the standard HTML tags (height, width).

  4. Place your logo in the PortalServer-dataDir/portals/portal-ID/web-src/enterprise/images directory.

  5. Redeploy the Portal Server to the web container.

    To redeploy, type PortalServer-base/bin/psadmin redeploy --adminuser amAdmin --passwordfile password-filename --portal portal-ID.


    Note –

    The image must first be placed in the portal web application source directory and then the portal web application should be redeployed. Otherwise, the change may be lost if the portal web application is ever redeployed.


  6. Verify that the new logo appears as desired by typing the following URL in your browser.


    http://yourserver:port/portal-ID/dt?desktop.suid=uid=authlessenterprisesample,ou=People,o=EnterpriseSample,dc=org,dc=com

ProcedureTo Add a Background Image

  1. Go to the Enterprise Sample CSS directory located under the portal data directory, PortalServer-DataDir/portals/portal-ID/web-src/enterprise/css.

  2. Modify the CSS file in the appropriate places

    For example:


    .channelBackground {
    background-image: url(../images/banner.jpg);
    background-repeat: no-repeat;
    background-position-x: left;
    background-position-y: top;
    border-bottom: 1px solid #9900FF;
    padding-bottom: 2px;
    }
    
    .channelBackgroundNoBorder {
    background-image: url(../images/your-banner-filename.jpg);
    background-repeat: no-repeat;
    background-position-x: left;
    background-position-y: top;
    border-bottom: 1px none #9900FF;

ProcedureTo Change the Background Color

  1. Go to the Enterprise Sample CSS directory located under the portal data directory, PortalServer-DataDir/portals/portal-ID/web-src/enterprise/css.

  2. Modify the CSS file in the appropriate places.

    Consider the following example where the defaultBody and altShortBody have been modified:


    defaultBody {...
    background-color: #your-hex-color-code
    }
    
    altShortBody {...
    background-color: #your-hex-color-code
    }

ProcedureTo Modify the Color Gradient Image

The gradient serves as the background color to the channels.

  1. Go to the Enterprise Sample CSS directory located under the portal data directory, PortalServer-DataDir/portals/portal-ID/web-src/enterprise/css.

  2. Modify the CSS file in the appropriate place.

    For example, replace the image channel-gradient-orange.gif with your new color gradient image.

    The following is a listing of the location of JSP and image files for the Enterprise Sample logo and banner.

    ASC Logo

    Files altShortBody-asc-logo.gif and asc-logo-8.png

    Located at PortalServer-DataDir/portals/portal-ID/web-src/enterprise/images directory

    ASC Banner

    File Header-alone-no-logo.jpg

    Located in PortalServer-DataDir/portals/portal-ID/web-src/enterprise/images directory

    ASC Title

    File title.jsp

    Located at PortalServer-DataDir/portals/portal-ID/desktop/enterprise_sample

    User Info Form

    File anonymous.jsp

    Located at PortalServer-DataDir/portals/portal-ID/desktop/enterprise_sample/JSPTabContainerProvider

    Banner Background Color

    PortalServer-DataDir/portals/portal-ID/web-src/enterprise/css

    Other Background and Positions

    PortalServer-DataDir/portals/portal-ID/web-src/enterprise/css

ProcedureTo Administer the Enterprise Sample Desktop from the Portal Server Management Console

This tasks lets users administer the enterprise sample desktop from the Portal Server Management Console.

  1. Log in to the Portal Server management console as administrator (amadmin).

  2. Click the Portals tab.

  3. Click the Portal ID in the Portals list.

  4. Select Enterprise Sample [Org] from the Select DN list.

  5. Click Manage Containers and Channels.

    You can administer channels and containers used by the Enterprise Sample from this page.

Branding the Desktop

This section describes how to brand the Desktop with your site’s logo and name.

Changing Desktop Colors

This section describes how to change the color for various Desktop components, such as header, footer, font color in the header and footer, and so on.