|
|
| Sun ONE Portal Server 6.0 Desktop Customization Guide |
Chapter 5 Understanding the Sample Portal
This chapter describes the sample portal that you can choose to install on your system during the Sun ONE Portal Server installation. See the Sun ONE Portal Server 6.0 Installation Guide for more information on installing the sample portal.
This chapter contains the following sections:
Overview of the Sample Portal
JSP-based Tab Container (JSPTabContainer)
JSP-based Table Container (JSPTableContainer)
Frame-based Container (FrameTabContainer)
Template-based Containers (TemplateTabContainer and TemplateTableContainer) Overview of the Sample Portal
The sample portal consists of sample containers, each of which produces a different looking Desktop. A container is a channel that is able to hold and organize content from other channels.The sample portal is created from the following containers:
JSPTabContainer - Creates a Desktop that contains multiple containers selected using different tabs. Normally, each tab is constructed by using JSPTabCustomTableContainer, but you can use any container. This container is JSP-based. Its provider is JSPTabContainerProvider.
JSPTableContainer - Creates a Desktop that arranges a maximum of five sub-containers into the channel arrangement. This container is JSP-based. Its provider is JSPTableContainerProvider.
FrameTabContainer - Creates a Desktop using frames. The left-hand frame enables you to navigate, and the right-hand frame displays the channels. This container is JSP-based. Its provider is JSPTabContainerProvider.
TemplateTabContainer - Creates a Desktop that contains multiple containers selected using different tabs. Normally, each tab is constructed by using TemplateTabCustomTableContainer, but you can use any container. This container is template-based. Its provider is TemplateTabContainerProvider.
TemplateTableContainer - Creates a Desktop that arranges a maximum of five sub-containers into the channel arrangement. This container is template-based. Its provider is TemplateTableContainerProvider. When you install the sample portal, the default channel is set to JSPTabContainer. Users can view this portal by typing:
You can easily view each sample portal Desktop by typing in the appropriate URL. See "Accessing the Desktop," on page 38 for more information.
Sun ONE Portal Server determines the user's default container by examining the Default Channel Name attribute in the Desktop page, in the iPlanet Directory Server Access Management Edition admin console.
The container architecture uses the various containers, and JavaServer Pages (JSP) or template files, to display the Desktop, and to build a hierarchy of containers that organize the Desktop content. Channels are defined at the global display profile level and are referenced by all the containers.
For more information on each container, see the appropriate section in this chapter.
Guidelines for Using the Sample Portal
Do not directly edit any of the files that make up the sample portal (display profile XML, JSP, and template files). Instead, make a copy of the sample portal to a new directory then modify those copied files. In this way you preserve the integrity of the sample portal. Additionally, if you later apply a patch to the portal server, you won't loose any changes you might have made to the sample portal files, as the patch would only overwrite the initially installed sample files.
You should also create a custom Desktop type for your users. For example, if the Desktop type were sesta, then you would create a /etc/opt/SUNWps/desktop/sesta directory to contain the template files that you have customized. You only need to copy the files that you have changed from the sample installation to the new directory tree. This structure enables you to tell at a glance which files have been modified from the original distribution. It also eliminates the need to back up copies of the original sample files.
Sample Portal Installation Directories
If you choose to install the sample portal, the installer locates the appropriate files in the following directories:
/opt/SUNWps/samples/desktop- Contains the following display profile documents:
dp-org.xml - Contains the display profile definitions for channels and containers.
dp-providers.xml - Contains the display profile definitions for providers.
Note The dp-providers.xml display profile document is loaded at the o=isp level, because the provider definition most likely will not change.
dp-org-final.xml - Contains the display profile definitions for channels and containers and includes NetMail and NetMail Lite definitions.
dp-anon.xml - Contains the display profile definitions for channels and containers for the authlessanonymous user in the default organization.
/etc/opt/SUNWps/desktop/default and /etc/opt/SUNWps/desktop/anonymous - Contains the JSP, template, and other support files. Desktop Theme Link
For the template-based containers, when you choose the Theme link, the look and feel of the toolbar changes slightly. (This is not the case for the JSP-based containers.) This happens because the template-based containers use JSPSingleContainer (which is a JSP-based container), and not a template-based container. Thus, the look and feel of the Theme page is "JSP," not "template."
JSP-based Tab Container (JSPTabContainer)
Figure 5-1 shows the JSP-based tab Desktop, JSPTabContainer, which provides a JSP-based tab container consisting of three tabs, My Front Page, Samples, and Search, and the following channels:
In the My Front Page tab: User Information, Sun ONE Information, My Bookmarks #2, Sample JSP, XML Test, Mailcheck Provider, My Bookmarks, and My Applications
In the Samples tab: Sun ONE Information, URL Scraper, Notes, and Pre-configured Web Service Figure 5-1    JSP Tab-Based Desktop (JSPTabContainer)
![]()
JSPTabContainer Architecture
Figure 5-2 shows the JSPTabContainer architecture. In this figure, tab.jsp is the top-level JSP file. The tab.jsp file makes include calls to the header.jsp, availableTabs.jsp, menubar.jsp, and footer.html files. The availableTabs.jsp file makes an include call to the selectedTab.jsp and tabs.jsp files.
See Appendix C, "JavaServer Pages Reference," more information on these JSP files.
JSPTabContainer is made up of three sub-containers, MyFrontPageTabPanelContainer, SamplesTabPanelContainer, and SearchTabPanelContainer, as represented by Tab1 (tablecontainer) in the figure.
Figure 5-2    JSPTabContainer Architecture
![]()
JSPTabContainer Actions
This section describes the various actions that you can perform within JSPTabContainer.
Banner Links
Home - Returns you to the Desktop Home page from customization pages and updates content.
Tabs - Lets you remove, rename, or select the start tab, and also create a new tab. The link for this page is:
Theme - Lets you edit the Desktop theme. The theme enables you to set the color scheme and font type for the Desktop. You can choose from preset themes or make your own colors for a custom theme. The link for this page is:
action=edit&provider=JSPPresetThemeContainer
The custom theme channel is defined as a JSPSingleContainerProvider channel, and has an entry in the display profile. See "JSPSingleContainerProvider," on page 51 for more information.
Help - Displays the Desktop sample online help. The link for this page is:
Log Out - Logs you out from the Desktop. The link for this page is:
Links Specific to the Contained Container
The contained container for JSPTabContainer is the table container that is currently selected, for example, MyFrontPageTabPanelContainer.
Content and Layout Links
The top-most JSP in the table container defines the Content and Layout links. JSPContentContainer is the container that displays the Content page, and JSPLayoutContainer is the container that displays the Layout page. The following describes the actions for these pages:
Content - Lets you edit the content for this particular tab on the Content page. The link for this page, when the My Front Page tab is selected, is:
action=edit&provider=JSPContentContainer&container=MyFrontPageTabPanelContainer&selected=My+Front+Page
Layout - Lets you edit the layout of the channels for this particular tab on the Layout page. The link for this page, when the My Front Page tab is selected, is:
JSPTabContainer Edit Pages
When you click the Tabs link on the Content Page, the Current Tabs Settings Edit page appears, where you can make changes.
Start page - Lets you set the starting tab.
Rename - Lets you rename the tab. (JavaScript handles the action.)
Delete - Lets you delete a tab from the Desktop. (JavaScript handles the action.) When you click Make a New Tab, the corresponding Edit page is shown. You decide what to name the tab and what the tab topics are. Clicking the Finished button renders the Content Page where channels can be selected for the new tab.
JSPTabContainerProvider Display Profile
The provider responsible for generating the JSPTabContainer channel is JSPTabContainerProvider. See "JSPTabContainerProvider," on page 50 for the display profile XML for this provider.
JSPTabContainer Channel Display Profile
The provider profile is the template which decides the properties for a container channel, but the container channel profile will ultimately decide the values for the container channel attributes. Code Example 5-1 shows the channel display profile for JSPTabContainer channel.
The properties that make up JSPTabContainer work as follows:
contentPage is set to tab.jsp. This draws the Content Page for the tab container.
editPage is set to tabedit.jsp. This displays the Edit page for the tab container where new tabs can be added, and existing tabs removed or renamed.
startTab sets the tab that opens first on the Desktop as MyFrontPageTabPanelContainer.
maxTabs allows four tabs to be created. As there are currently three tabs, one more can be added.
makeTabProvider specifies JSPTabCustomTableContainerProvider as the provider to create a new tab on the Desktop.
channelNumber specifies that a number is appended to a newly created tab as the channel name. This number is increased each time a new tab is created, so that the new tab will have unique name. For example, to create a new tab based on MyFrontPageTabPanelContainer in JSPTabContainer, the new tab channel name would be JSPTabContainer/MyFrontPageTabPanelContainer1. (The new tab name is actually the channelName property in the display profile plus the the value of channelNumber. channelNumber is incremented by one each time a new tab is created.)
contentChannel specifies JSPContentContainer as the content channel that provides the Content page displaying channels to add to a user-created tab.
The collection TabProperties has <Collection name=> entries for each of the three tabs that appear.
The collection defaultChannelList describes a list of channels that are included in the available and selected lists for a newly created tab.
The collection propertiesToCopy sets the initial properties to be defined in a newly created tab container.
The Available list describes all available channels for this container. The available channels are displayed in the Content Preference page for users to select from.
The Selected list describes selected channels for this container. Only selected channels shows up in the Desktop. Contained Containers' Display Profile
The JSP tab container channel has MyFrontPageTabContainer, SamplesTabPanelContainer, and SearchTabPanelContainer as its contained channels. Code Example 5-2, Code Example 5-3, and Code Example 5-4 show the pertinent display profile.
JSP Files Used by JSPTabContainer
Sun ONE Portal Server uses JSP files for a channel's presentation layer. JSPTabContainer references two main JSPs, tab.jsp and tabedit.jsp, through the contentPage and editPage properties.
Content template is responsible for the front page of the container channel and the file name for the tab container channel is tab.jsp. The tab.jsp file extensively uses the Desktop taglibs. For more information on taglibs, see Appendix B, "JavaServer Pages Tag Library Reference."
The Edit page is where you can add, remove, and rename tabs. The tabedit.jsp is used to display this page. For a description of all JSP files used by JSPTabContainer, see Table C-15 on page 286.
JSP-based Table Container (JSPTableContainer)
Figure 5-3 shows the JSP-based table Desktop, JSPTableContainer, which provides a JSP-based table container consisting of the following channels:
Thin channels: User Information, Sun ONE Information, My Bookmarks, Mailcheck Provider, and My Applications
Wide channels: Sample JSP, XML Test, Notes, and Preconfigured Web Service Figure 5-3    JSP Table-Based Desktop (JSPTableContainer)
![]()
JSPTableContainer Architecture
Figure 5-4 shows the JSPTableContainer architecture. In this figure, toptable.jsp is the top-level JSP file. The toptable.jsp file makes include calls to the header.jsp, launchPopup.jsp, leafWrapper.jsp, and menubar.jsp files.
See Appendix C, "JavaServer Pages Reference," more information on these JSP files.
The default layout for JSPTableContainer is set to 1, which gives the thin-wide columns for the table. In Figure 5-4, Channels One, Two, and Three are thin channels, and Channels Four and Five are wide channels.
Figure 5-4    JSPTableContainer Architecture
![]()
JSPTableContainer Actions
This section describes the various actions that you can perform within JSPTableContainer.
Banner Links
Home - Returns you to the Desktop Home page from customization pages and updates content.
Theme - Lets you edit the Desktop theme. The theme enables you to set the color scheme and font type for the Desktop. You can choose from preset themes or make your own colors for a custom theme. The link for this page is:
action=edit&provider=JSPPresetThemeContainer
The custom theme channel is defined as a JSPSingleContainerProvider channel, and has an entry in the display profile. See "JSPSingleContainerProvider," on page 51 for more information.
Log Out - Logs you out from the Desktop. The link for this page is:
Help - Displays the Desktop sample online help. The link for this page is:
Links Specific to the Contained Container
JSPTableContainer does not use a contained container.
Content and Layout Links
The toptable.jsp file defines the Content and Layout links. JSPContentContainer is the container that displays the Content page, and JSPLayoutContainer is the container that displays the Layout page. The following describes the actions for these pages:
Content - Lets you edit the content on the Content page. The link for this page is:
Layout - Lets you edit the layout of the channels on the Layout page. The link for this page is:
JSPTableContainerProvider Display Profile
The provider responsible for generating the JSPTableContainer channel is JSPTableContainerProvider. See "JSPTableContainerProvider," on page 48 for the display profile XML for this provider.
JSPTableContainer Channel Display Profile
The provider profile is the template which decides the properties for a container channel, but the container channel profile will ultimately decide the values for the container channel attributes. Code Example 5-5 shows the channel display profile for JSPTableContainer channel.
Container's Display Profile
The properties that make up JSPTableContainer work as follows:
contentPage is set to toptable.jsp. This draws the Content Page for the table container.
The collection categories defines the categories that appear in the Content page. Here there are three categories: Personal Channels, Sample Channels, and News Channels.
The collection channelsRow, and values that appear in this collection, contain the row number value for channels in this container. For example, the mail check channel is defined as row 4.
The collection channelsIsRemovable defines a collection to contain the isRemovable value for channels in this container. Only one channel, user information, is defined, with a value of false, so that it cannot be removed.
The Available list describes all available channels for this container. The available channels are displayed in the content preference page for users to select from.
The Selected list describes selected channels for this container. Only selected channels shows up in the Desktop. JSP Files Used by JSPTableContainer
Sun ONE Portal Server uses JSP files for a channel's presentation layer. JSPTableContainer references one main JSPs, toptable.jsp, through the contentPage property.
Content template is responsible for the front page of the container channel and the file name for the tab container channel is toptable.jsp. The toptable.jsp file extensively uses the Desktop taglibs. For more information on taglibs, see Appendix B, "JavaServer Pages Tag Library Reference."
For a description of all JSP files used by JSPTabContainer, see Table C-18 on page 289.
Frame-based Container (FrameTabContainer)
Figure 5-5 shows the frame-based table Desktop, FrameTabContainer, which provides a frame-based table container consisting of two frames, My Front Page and Samples, with the following channels:
In the My Front Page frame: User Information, Sun ONE Information, My Bookmarks, Mailcheck Provider, My Applications, Sample JSP, and XML Test
In the Samples frame: Sun ONE Information, URL Scraper, Notes, and Preconfigured Web Service Figure 5-5    Frame-Based Desktop (FrameTabContainer)
![]()
FrameTabContainer Architecture
Figure 5-6 shows the FrameTabContainer architecture. In this figure, frametab.jsp is the top-level JSP file. The frametab.jsp file makes include calls to the frametabmenu.jsp, header.jsp, banner.jsp, selectedTab.jsp, menubar.jsp, frameset.jsp, and footer.html files.
See Appendix C, "JavaServer Pages Reference," more information on these JSP files.
FrameTabContainer is made up of two sub-containers, MyFrontPageFramePanelContainer and SamplesFramePanelContainer, as represented by Page 1 (tablecontainer) in the figure.
Figure 5-6    FrameTabContainer Architecture
![]()
FrameTabContainer Actions
This section describes the various actions that you can perform within FrameTabContainer.
Banner Links
Home - Returns you to the Desktop Home page from customization pages and updates content.
Sections - Lets you rename or select the start page, delete a page, and also create a new page. The link for this page is:
Theme - Lets you edit the Desktop theme. The theme enables you to set the color scheme and font type for the Desktop. You can choose from preset themes or make your own colors for a custom theme. The link for this page is:
action=edit&provider=JSPPresetThemeContainer
The custom theme channel is defined as a JSPSingleContainerProvider channel, and has an entry in the display profile. See "JSPSingleContainerProvider," on page 51 for more information.
Help - Displays the Desktop sample online help. The link for this page is:
Log Out - Logs you out from the Desktop. The link for this page is:
Links Specific to the Contained Container
The contained container for the FrameabContainer is JSPContentContainer.
Content and Layout Links
The top-most JSP in the table container defines the Content and Layout links. JSPContentContainer is the container that displays the Content page, and JSPLayoutContainer is the container that displays the Layout page. The following describes the actions for these pages:
Content - Lets you edit the content for this particular page on the Content page. The link for this page, when My Front Page is selected, is:
Layout - Lets you edit the layout of the channels for this particular page on the Layout page. The link for this page, when the My Front Page tab is selected, is:
FrameTabContainer Edit Pages
When you click the Sections link on the Content page, the Current Page Settings Edit page appears, where you can make changes.
Start page - Lets you set the starting page.
Rename - Lets you rename the page. (JavaScript handles the action.)
Delete - Lets you delete a page from the Desktop. (JavaScript handles the action.) When you click Make a New Page, the corresponding Edit page is shown. You decide what to name the page and what the page topics are. Clicking the Finished button renders the Content Page where channels can be selected for the new page.
JSPTabContainerProvider Display Profile
The provider responsible for generating FrameTabContainer channel is JSPTabContainerProvider. See "JSPTabContainerProvider," on page 50 for the display profile XML for this provider.
FrameTabContainer Channel Display Profile
The provider profile is the template which decides the properties for a container channel, but the container channel profile will ultimately decide the values for the container channel attributes. Code Example 5-6 shows the channel display profile for FrameTabContainer channel.
The properties that make up FrameTabContainer work as follows:
contentPage is set to frametab.jsp. This draws the Content Page for the frame container.
editPage is set to frametabedit.jsp. This displays the Edit page for the frame container where new pages can be added, or existing pages removed or renamed.
startTab sets the page that opens first on the Desktop as MyFrontPageFramePanelContainer.
maxTabs allows four pages to be created. As there are currently two pages, two more can be added.
makeTabProvider specifies JSPFrameCustomTableContainerProvider as the provider to create a new page on the Desktop.
channelNumber specifies that a number is appended to a newly created page as the channel name. This number is increased each time a new page is created, so that the new page will have unique name. For example, to create a new page based on MyFrontPageFramePanelContainer in FrameTabContainer, the new page channel name would be FrameTabContainer/MyFrontPageFramePanelContainer1. (The new page name is actually the channelName property in the display profile plus the the value of channelNumber. channelNumber is incremented by one each time a new page is created.)
contentChannel specifies JSPContentContainer as the content channel that provides the Content page displaying channels to add to a user-created page.
The collection TabProperties has <Collection name=> entries for each of the two pages that appear, and one for when a user creates a new page (FrameCustomTableContainer).
The collection defaultChannelList describes a list of channels that are included in the available and selected lists for a newly created page.
The collection propertiesToCopy specifies sets the initial properties to be defined in a newly created container.
The Available list describes all available channels for this container. The available channels are displayed in the content preference page for users to select from.
The Selected list describes selected channels for this container. Only selected channels shows up in the Desktop. Contained Containers' Display Profile
The frame tab container channel has MyFrontPageFramePanelContainer and SamplesFramePanelContainer as its contained channels. Code Example 5-7 and Code Example 5-8 show the pertinent display profile.
JSP Files Used by FrameTabContainer
Sun ONE Portal Server uses JSP files for a channel's presentation layer. FrameTabContainer references two main JSPs, frametab.jsp and frametabedit.jsp, through the contentPage and editPage properties.
Content template is responsible for the front page of the container channel and the file name for the tab container channel is frametab.jsp. The frametab.jsp file extensively uses the Desktop taglibs. For more information on taglibs, see Appendix B, "JavaServer Pages Tag Library Reference."
The Edit page is where you can add, remove, and rename pages. The frametabedit.jsp is used to display this page. For a description of all JSP files used by FrameTabContainer, see Table C-4 on page 280.
Template-based Containers (TemplateTabContainer and TemplateTableContainer)
TemplateTabContainer and TemplateTableContainer use the original template mechanism from iPlanet Portal Server 3.0. TemplateTableContainer is the same as the normal Desktop from iPlanet Portal Server 3.0, and TemplateTabContainer is the same as the tabbed Desktop from iPlanet Portal Server 3.0. You use these containers for migrating from existing iPlanet Portal Server 3.0 (Service Pack 3a or 4) custom Desktops to Sun ONE Portal Server 6.0.
See Chapter 5, "Migrating the Desktop," in the Sun ONE Portal Server 6.0 Migration Guide for more information.
Previous Contents Index Next
Copyright 2002 Sun Microsystems, Inc. All rights reserved.
Last Updated August 30, 2002