IBM portlet DTD tag reference
Learn about the elements in the portlet deployment descriptors for the IBM Portlet API.
Following is a description of the structure of the portlet deployment descriptors. For information about the standard portlet deployment descriptors, refer to the Java Portlet Specification.
<portlet-app-def>
Required. Top level element containing information about the portlet application. This element includes exactly one <portlet-app> element and one or more <concrete-portlet-app> elements.
- <portlet-app uid="uid">
- Required. Contains information about the portlet application. The uid for each portlet must be unique within the portlet application. Refer to the section about Guidelines for portlet application identifiers under the topic about Deployment descriptors. The following are subelements of <portlet-app>.
- <portlet-app-name>
- Exactly one is required. The name of the portlet application.
- <portlet id="id" href="http://setgetweb.com/p/portal80/href" major-version="version" minor-version="version">
- At least one is required. Contains elements describing a portlet that belongs to this portlet application. id and href is required. The id must be unique within the portlet application. The href attribute points to the identifier of the servlet, as in WEB-INF/web.xml#servlet_id .
Use the version attributes for maintaining and supporting multiple versions of the portlet. The following are subelements of <portlet>:
- <portlet-name>
- Required. The name of the portlet. This name does not appear on the portal page.
- <cache>
- Optional. Describes how the portal handles caching the output of this portlet. Servlet caching must be enabled on the application server to support caching of portlet output. The following are subelements of <cache>:
- <expires>
- Required if <cache> is specified. The number of seconds after which the portlet's output is refreshed.
- 0 indicates that the portlet's output always expires. Each request causes the portlet to refresh its output. Default.setting if <cache> is not present.
- Any number greater than 0 indicates the number of seconds the portlet output is cached. After the cache time expires, subsequent requests cause the portlet to refresh its output.
- -1 indicates that the portlets output never expires. After the portlet is initialized, its content is no longer refreshed.
- <shared>
- Required if <cache> is specified. Indicates if the portlet output is cached and shared with all users or for each individual user. Specify "yes" or "no".
- <allows>
- Optional. The states supported by the portlet. No more than one <allows> element can be specified for a portlet. These settings only affect the rendering of portlets in HTML. The following are subelements of <allows>:
- <maximized/>
- Optional. Whether the portlet can be maximized. When maximized, the portlet replaces all other portlets on the portal page. If this element is present, the maximize button is rendered on the portlet's title bar.
- <minimized/>
- Optional. Whether the portlet can be minimized. When minimized, the portlet is rendered only as a title bar. If this element is present, the minimize button is rendered on the portlet's title bar.
- <supports>
- Required. The modes and markup types supported by the portlet. All portlets must support the view mode. Other modes must be provided only if they are supported by the portlet. The following are subelements of <supports>:
- <markup name="name">
- At least one is required. The type of markup this portlet supports. name is one of the following values:
- html
- wml
- chtml
Indicate one <markup> tag for each markup type, for example:
<markup name="html"> ... </markup> <markup name="wml"> ... </markup>The following are subelements of <markup>:
- <view/>
- Required. Indicatesthat this portlet supports view mode.
- <edit/>
- Optional. Indicatesthat this portlet supports edit mode. Optional. If edit mode is supported, the portlet must supply methods that users can invoke to customize the portlet for their own use.
- <help/>
- Optional. Indicatesthat this portlet supports help mode. Optional. If help mode is supported, the portlet must supply help output that will display in place of the portlet when the user clicks the help icon.
- <configure/>
- Optional. Indicatesthat this portlet supports configure mode. Optional.
- <concrete-portlet-app uid="uid">
- At least one is required. Contains information about the concrete portlet application. The following are subelements of <concrete-portlet-app>.
- <portlet-app-name>
- Exactly one is required. The name of the portlet application.
- <context-param>
- Optional. Contains a pair of <param-name> and <param-value> elements that this concrete portlet application can accept as input parameters. A concrete portlet application can accept any number of context parameters. Administrators can change the context parameters when they configure the concrete portlet application. Provide help information using XML comments to explain what values the portlet application can accept. The unique configuration settings for a concrete portlet application make up its portlet application settings. Refer to the appropriate section under the topic about Configuration objects.
- <concrete-portlet id="id" href="http://setgetweb.com/p/portal80/href">
- At least one is required. Contains elements describing the concrete portlet that belongs to this concrete portlet application. id and href are required. The id must be unique within the portlet application. The href attribute points to the identifier of the portlet, as in #portlet_id . The following are subelements of <concrete-portlet>:
- <portlet-name>
- Required. The name of the portlet. This name does not appear on the portal page.
- <default-locale>
- Required. Indicate the locall that will be used if the client locale cannot be determined.
- <language locale="locale">
- At least one is required. Provide one <language> element for each locall that the portlet supports. locale can have one of the following values:
- en English
- de German
- fr French
- es Spanish
- ja Japanese
- ko Korean
- zh Simplified Chinese
- zh_TW Traditional Chinese
- pt_BR Brazilian Portuguese
- it Italian
- iw Hebrew
- cs Czechoslovakian
- tr Turkish
- pl Polish
The following are subelements of <language>:
- <title>
- Exactly one <title> is required for each <language> element. Specify a portlet title translated for the given locale.
- <title-short>
- Optional. Indicates a translated short title.
- <description>
- Optional. Provides a translated description of the portlet.
- <keywords>
- Optional. Provides any translated keywords associated with your portlet.
- <config-param>
- Contains a pair of <param-name> and <param-value> elements that this portlet can accept as input parameters. A portlet can accept any number of configuration parameters. Administrators can change the configuration parameters when they configure the concrete portlet. Provide help information using XML comments to explain what values the portlet application can accept. The unique configuration settings for a concrete portlet make up its portlet settings. Refer to the appropriate section under the topic about Configuration objects.
Parent: Portlet development reference
Related:
Markup guidelines
Build .ear and .war files
Access the portlet session on the anonymous page
Deployment descriptors
JSP tags for standard portlets
JSP tags for IBM portlets
Handling and visibility of request parameters in portlets
Detailed descriptions of the Struts WML tags
Application extension registry