+

Search Tips   |   Advanced Search

Configure Portlet Bridge for JavaServer Faces

Configure IBM Portlet Bridge for JavaServer Faces (JSF).

The following procedure does not apply to v9.0 users without a fix pack:


Tasks

  1. Open the portlet.xml file and modify the portlet class for JSF Portlet Bridge.
    <portlet-class>com.ibm.faces20.portlet.FacesPortlet</portlet-class>
    		<init-param>
    				<name>com.ibm.faces.portlet.page.view</name>
    				<value>/TestProjectView.xhtml</value>
    		<init-param>
    

    1. Open the portlet.xml file and modify the portlet class for JSF 2.2 Portlet Bridge.
      <portlet-class>com.ibm.faces20.portlet.FacesPortlet</portlet-class>
      		<init-param>
      				<name>com.ibm.faces.portlet.page.view</name>
      				<value>/TestProjectView.xhtml</value>
      		<init-param>
      

  2. Open the faces-config.xml file and add the JSF portlet bridge variable resolver, view handler, and resource handler entry.
    <application>
    		<el-resolver>com.ibm.faces20.portlet.PortletELResolver</el-resolver>
    		<view-handler>com.ibm.faces20.portlet.FaceletPortletViewHandler</view-handler>
    		<resource-handler>com.ibm.faces20.portlet.httpbridge.PortletResourceHandler</resource-handler>
    </application>
    

    1. Add the JSF 2.2 portlet bridge variable resolver, view handler, and resource handler entry.
      <application>
                   <el-resolver>com.ibm.faces20.portlet.PortletELResolver</el-resolver>
      		<view-handler>com.ibm.faces20.portlet.FaceletPortletViewHandler</view-handler>
      		<resource-handler>com.ibm.faces20.portlet.httpbridge.PortletResourceHandler</resource-handler>
      </application>
      

  3. Register the listener in the web.xml file.
    <listener>
    		<listener-class>com.ibm.faces20.portlet.httpbridge.PortletRequestAttributesListener
    		</listener-class>
    </listener>
    


What to do next

If the portlet project has a custom portlet class, these changes are also necessary:


Related:

  • (ZOS) JavaServer Faces
  • JavaServer Faces widget library (JWL)
  • JavaServer Faces
  • Portlets
  • JavaServer Faces 2.2 feature functions
  • Configure for JavaServer Faces 2.2
  • http://www.ibm.com/support/knowledgecenter/SSRTLW_9.0.0/com.ibm.portal.doc/topics/tjsf20_Migration_page.html