Oracle9iAS Portal Developer Kit
How to Build a URL-Based Portlet with Inline Rendering of Portlet Links

In the article How to Build a URL-Based Portlet, you learnt how to create a portlet that displayed the content of a URL-based application.  The example used in that article was Google.com.    Since many URL-based applications (including Google.com) display links inside their HTML, you may find it desirable to have these links render inside the portlet container.  For example, when you click on a link, you may want to see the portlet render again displaying the destination page as its content (as opposed to seeing the whole browser window display the destination page).  PDK-URL Services enables you to select inline rendering as a feature for your URL-based portlets.

 

This article describes how to build a URL-based portlet that renders its portlet links inside the portlet container.  It extends the Google.com sample found in the article, How to Build a URL-Based Portlet.

ASSUMPTIONS

  1. You have successfully installed the PDK-Java runtime and samples by following the article Installing the PDK-Java Framework and Samples.

  2. You have successfully installed the PDK-URL Services runtime and samples by following the article Installing the PDK-URL Services Samples

  3. You have successfully installed the Google.com URL-based portlet by following the article How to Build a URL-Based Portlet.

CREATING AN XML PROVIDER DEFINITION

This section explains how to create an XML provider definition for your URL-based portlet provider.

  1. Using a text editor, create an XML file for your portlet provider. 

    The following sample is the same as that found in the article How to Build a URL-Based Portlet.  It displays Google.com within the portlet.  However, this time it uses the inlineRendering tag to specify that portlet links are to be rendered within the portlet container.  Please refer to the article Understanding provider.xml for PDK-URL Services for an explanation of the required XML tags and their functions.

  1. Save the file as "provider.xml", making sure it overwrites the provider.xml file you created from the article How to Build a URL-Based Portlet (you may wish to make a backup copy of the older provider.xml file).

ADDING THE URL-BASED PORTLET TO A PAGE

Since you configured and registered the Google.com portlet provider when following the article How to Build a URL-Based Portlet, you simply need to stop and restart the Oracle HTTP Server and refresh the portlet provider through the Edit Provider screen. Now you are ready to add the inline rendering-enabled Google.com portlet to a page.

Now that you have successfully added inline rendering to your URL-based portlet, please look for other portlet development articles that describe how to add extra features to your portlet, including single sign-on to external URL-based applications, HTML and XML filtering, parameter passing, and more.

Here are some reference articles to help you better understand the architecture and technical details of PDK-URL Services:


Revision History: