Providing Custom Tools and Services with Portlets
Portlets provide portal
users customized tools and services as well as information. Portlets
let you to integrate applications, tools, and services into your portal,
while taking advantage of portal security, caching, and customization. Users can then add these portlets to their My Pages or to community
pages.
Before you create a portlet, you must:
- Install the portlet code on the computer that hosts the portal
or, if your portlet does not rely on any portal code, you can instead
install it on another computer
- If you installed the portlet code on a computer other than the
one that hosts the portal, create a remote server to point to the
remote computer
- Create a portlet web service on which to base your portlet
- Optionally, create a portlet template on which to base your portlet
To create a portlet you must have the
following rights and privileges:
- Access Administration activity right
- Create Portlets activity right
- At least Edit access to the parent folder (the folder that will
store the portlet)
- Click Administration.
- Open the folder in which you want to store the portlet.
- In the Create Object drop-down list,
click Portlet.
The Choose Template or Web Service dialog box opens.
- Select the template or web service that provides the basic
settings for your portlet and click OK.
Use a template when possible. When you use a template, your
portlet inherits the template's web service as well as its default
settings. Some web services that are designed to work with templates
might not work correctly if you bypass the template and make a new
portlet directly from the web service object.
The Portlet Editor opens.
- On the Main Settings page, complete
the following tasks:
- Click the Properties and Names page
and complete the following tasks:
The default security for this portlet is based on the security
of the parent folder. You can change the security when you save this
portlet (on the Security tab page in the Save
As dialog box), or by editing this portlet (on the Security page of the Portlet Editor).
- Specifying the Size, Type, and Orientation for a PortletYou can specify the size, type, and orientation for a portlet on the Main Settings page of the Portlet Editor.
- Caching Portlet ContentYou might occasionally want to run a job to cache portlet content (for example, if the portlet takes a couple minutes to render). When the job runs, it creates a snapshot of the portlet content (in the form of a static HTML file) that can be displayed on a web site. The file is stored in the shared files directory (for example, C:\bea\alui\ptportal\10.3.0) in \StagedContent\Portlets\<portletID>\Main.html. You can then create another portlet that simply displays the static HTML.
- Setting Security for a PortletBy default, a new portlet inherits the security of the parent folder, but you can change the security of each individual portlet.