Using Attributes to Enhance Pagelets
This section provides an overview of pagelet and content reference attributes and discusses how to:
Manage pagelet attributes.
Configure pagelet Help links.
Configure pagelet time-outs.
Configure automatic pagelet refresh attributes.
Create banner pagelets.
Add images to pagelet headers.
Pagelet and content reference attributes provide a framework to specify and store free-form information about a content reference or pagelet. Attributes also enable you to manage pagelet behavior and appearance.
When you click a content reference, the portal retrieves the URL for the pagelet or content reference, it reads and processes the attribute and its value, and renders the page or pagelet incorporating the attribute.
You add attributes by entering Name-Value pairs. For example, an attribute name is PORTAL_BANNER_PGLT. You use this attribute to define a pagelet as a banner pagelet, which is the only pagelet that can span the enter width of the transaction page that appears in the browser in your PeopleSoft applications. The possible attribute values for this attribute are 1, 2, and 3. Each number represents different options regarding the appearance of the banner pagelet.
Access the Content Ref Administration page. (Select Edit link for the appropriate content reference.)
Click theSelect Pagelet in the Usage Type drop-down list box.
Use the Pagelet Attributes group box to select the default column for a pagelet, associate a help topic with the pagelet, set refresh time, and hide certain buttons from users.
Use the Content Reference Attributes group box to create banner pagelets and add images to pagelet headers
Image: Pagelet Attributes and Content Reference Attributes group boxes
Use the Pagelet Attributes and Content Reference Attributes group boxes to enhance pagelets as shown in this example:
The following screenshot illustrates an example to enhance pagelets by using pagelet and content reference attributes.
![Pagelet Attributes and Content Reference Attributes group boxes](img/ia2cf27cn-7fe1.png)
Pagelet Attributes
Field or Control |
Definition |
---|---|
Default Column |
Select the column in which the pagelet appears. |
Help ID |
Enter the help ID for the pagelet. When users click the Help link, the PeopleSoft system opens a new window displaying online help documentation for this item. Note: You must also configure a help URL on the Web Profile Configuration - General page. |
Refresh Time (sec) |
Enter the number of seconds after which the system auto-refreshes the pagelet. To activate the refresh timer, enter a value of 1 or greater. The timer refreshes the pagelet as soon as the user accesses the homepage and then automatically refreshes the pagelet every n number of seconds. Note: Homepages and dashboards use automatic refresh. |
Hide minimize image |
Select to hide the minimize button that normally appears in the pagelet headerso that users are prevented from minimizing the pagelet. |
Hide refresh image |
Select to hide the refresh button to prevent users from refreshing the pagelet. If you implemented pagelet caching for this pagelet, a refresh button automatically appears in the pagelet header. |
Force Pagelet Refresh |
Some components can render themselves differently based on the column width. When a homepage has a two-column layout and the user moves a component-based pagelet to a different sized column by using the drag-and-drop method, this pagelet needs to be refreshed so that the content displays correctly. The drag-and-drop iScript that persists the pagelet changes forces a homepage refresh only when all of the following conditions are met:
|
Note: When document.write
or document.writeln
commands are detected inside a pagelet, the whole homepage will
be refreshed instead of just that pagelet. This is required to properly
assemble that pagelet's content.
You can use a combination of a web profile setting and the PORTAL_NOBROWSERCACHE content reference attribute to determine whether an individual pagelet can be cached. See Configuring Caching and Implementing Homepage Caching.
Separately, you can also administer server-based caching. See Implementing Pagelet Caching.
Edit URL Information
Use the Node Name and URL Type fields to specify a page to be used for personalizing this pagelet and to make the personalization button appear in the pagelet header.
Field or Control |
Definition |
---|---|
Node Name |
Select the node name for the edit URL of the pagelet. This node name can be different from the pagelet node name. |
URL Type |
Select the type of edit URL. The specific URL entry fields appear based on the setting of this field. Options are: Non-PeopleSoft URL: The Edit URL field appears. Enter the URL of the personalization page to use. PeopleSoft Component: The Component Parameters group box appears, containing the same fields as the Component Parameters group box for the content reference. Use these fields to identify the personalization page to use. PeopleSoft Script: The iScript Parameters group box appears, containing the same fields as the iScript Parameters group box for the content reference. Use these fields to identify the personalization page to use. |
Content Reference Attributes
You can use the content reference attributes of a pagelet to change its character and appearance and to improve its usability.
Use content reference attributes to:
Configure pagelet help links.
Configure pagelet time-out settings.
Configure automatic pagelet refresh.
Suppress parallel pagelet loading (for pagelets with global variables).
Create banner pagelets.
Add icons to pagelet headers.
To specify pagelet help:
Select
.Click the Portal Objects link.
Click the Pagelets link.
Navigate to the Content Ref Administration page for the pagelet.
You define the pagelet help in the Content Reference Attributes region of the page.
Enter PTPPB_PAGELET_HELP_LINK in the Name field.
Leave the Label field blank.
Deselect the Translate check box.
Note: You must deselect the Translate check box or unexpected results might occur.
In the Attribute Value field, enter the URL of the location of your help document, for example http://www.example.com/help_doc1.html
Save the content reference.
Note: The pagelet Help URL takes precedence over the Help ID when both attributes are set for a pagelet.
Note: The Help button appears only when the pagelet is on the homepage inside the PeopleSoft Portal; it does not appear when the pagelet is displayed as a WSRP portlet.
To specify a pagelet time-out:
Select
.Click the Portal Objects link.
Click the Pagelets link.
Navigate to the Content Ref Administration page for the pagelet.
You define the pagelet help in the Content Reference Attributes region of the page.
Enter PSTIMEOUT in the Name field.
Enter PSTimeout in the Label field.
In the Attribute Value field, enter the number of seconds before the pagelet is considered unavailable. This can be any positive integer.
Note: The portal ignores this attribute if you enter 0 or a negative value, or if the content reference isn't a pagelet.
Save the content reference.
When your specified time-out expires, the portal stops attempting to load the pagelet and generates an error message.
To specify a pagelet refresh time in seconds:
Select
.Click the Portal Objects link.
Click the Pagelets link.
Navigate to the Content Ref Administration page for the pagelet.
You define the pagelet help in the Content Reference Attributes region of the page.
Enter the number of seconds for automatic refresh in the Refresh Time (sec) field.
(Optional) Select the Hide refresh image check box to prevent manual pagelet refresh by the user.
Save the content reference.
Note: Pagelets with document.write or document.writeln must not have the refresh timer set (to automatically refresh every n seconds) because the whole homepage will also be refreshed every n seconds.
To create banner pagelets:
Create and register your pagelet.
Access the Structure and Content page (Select
).Select Portal Objects, then Pagelets in the portal registry folder structure and click the Add Content Reference link.
If you have already registered the pagelet, navigate to the Pagelets folder and click the Edit link that is associated with the pagelet.
In the Content Reference Attributes group box, enter PORTAL_BANNER_PGLT in the Name field.
In the Attribute value field, enter one of these values:
1 - The banner pagelet will display a pagelet header and a border around the pagelet content like a standard pagelet.
2 - The banner pagelet will display a border around the pagelet content, but no pagelet header.
3 - The banner pagelet will display neither a pagelet header nor a border around the pagelet content.
Add the pagelet to the homepage.
See Selecting the Pagelets or Tiles That Appear on Homepages.
Click the Save button.
To add images to pagelet headers:
In PeopleSoft Application Designer, create an image definition and store the image in the image catalog.
In your browser, access the Structure and Content page (Select
)Navigate through the Portal Objects folder structure to the Pagelets folder until you find the pagelet content reference. Then, click the Edit link.
In the Content Reference Attributes group box, enter PT_PORTAL_PGLT_HDR_IMG in the Name field.
In the Attribute value field, enter the name of the image definition that you want to appear in the pagelet header.
Important! The image definition must exist in the image catalog of the PeopleTools portal database. Use PeopleSoft Application Designer to manage the image definitions that comprise the image catalog.
Click the Save button.