To add Faces JSR 168 portlet modes and their initial pages, or
change an initial page value, you must edit configuration parameters using
the Portlet Deployment Descriptor editor.
- Open the portlet.xml file (double-click the Portlet
Deployment Descriptor node in the Project Explorer) in the Faces portlet project
to which you want to add new modes.
- Click the Portlets tab.
- In the Portlets section on the left side,
select the portlet that you want to modify.
- In the Initialization section on the right
side (you may need to scroll down), click the Add button
to add a new parameter. If you merely want to change the JSP path for an existing
initial page, select the parameter in the table and click Edit. Depending on which button you clicked, the New Initialization
Parameter or Edit Initialization Parameter dialog
will open.
- Type the appropriate mode name, based on the table below, and JSP
path value (relative to the project context root) for the initial page. Click OK.
Mode |
JSP path |
com.ibm.faces.portlet.page.view |
An initial JSP file path for the View mode |
com.ibm.faces.portlet.page.edit |
An initial JSP file path for the Edit mode |
com.ibm.faces.portlet.page.help |
An initial JSP file path for the Help mode |
com.ibm.faces.portlet.page.config |
An initial JSP file path for the Configure mode |
- Save the portal.xml file.
If you select the
Source page and scroll to
the place in the portal.xml file where configuration parameters are defined,
you should see generated results similar to the following example:
<init-param>
<name>com.ibm.faces.portlet.page.edit</name>
<value>/jsp/MyEdit.jsp</value>
</init-param>