-
1. Re: richfaces 4 example without seam
ilya40umov Dec 30, 2010 4:07 PM (in response to senthilnz)You can download the latest version of RF 4.0 showcase and look into its web.xml and faces-config.xml.
-
2. Re: richfaces 4 example without seam
nbelaevski Dec 30, 2010 5:04 PM (in response to senthilnz)Hi,
No special settings (except a4j:push component that requires additional setup). For RF 4 & JSF 2.0 there is no need to use Facelets 1.x and disable built-in JSF view handler - so this should be changed during migration.
-
3. Re: richfaces 4 example without seam
senthilnz Dec 30, 2010 6:20 PM (in response to nbelaevski)Hi Nick,
Thanks for the answer!!
I actually tried the same way as its described in the richfaces-showcase project's web.xml and faces-config.xml file. Here, only jsf tag was working but the richfaces are not working. It thrown the below expception while trying to load pages with richfaces tag on it,
dropDownPage.xhtml @12,15 <rich:toolBar> Tag Library supports namespace: http://richfaces.org/rich, but no tag was defined for name: toolBar
As you mentioned, I did the below changes in the faces-config.xml file but with this change the no pages were shown instead the blank page was displayed.
<context-param>
<param-name>javax.faces.DISABLE_FACELET_JSF_VIEWHANDLER</param-name>
<param-value>true</param-value>
</context-param>I faced similar issue with richfaces3.3.3 but that was resolved after disabling built-in facelet but in richfaces3.3.3 we had org.ajax4jsf.Filter this helped in rendering page and was loaded correctly.
My environment settings are as follows,
JBoss AS 6
Richfaces 4.0
Included jars are,
commons-beanutils.jar
commons-collections.jar
commons-digester.jar
commons-logging.jar
jstl-1.2.jar
richfaces-components-api-4.0.0.20101110-M4.jar
richfaces-components-ui-4.0.0.20101110-M4.jar
richfaces-core-api-4.0.0.20101110-M4.jar
richfaces-core-impl-4.0.0.20101110-M4.jarfaces-config.xml file content is,
<?xml version='1.0' encoding='UTF-8'?>
<faces-config xmlns="http://java.sun.com/xml/ns/javaee"
version="2.0"><application>
<!-- system-event-listener>
<system-event-listener-class>org.richfaces.resource.MapBasedResourceCodecListener</system-event-listener-class>
<system-event-class>javax.faces.event.PostConstructApplicationEvent</system-event-class>
</system-event-listener -->
</application><managed-bean>
<managed-bean-name>loginBean</managed-bean-name>
<managed-bean-class>com.tutorial.LoginBean</managed-bean-class>
<managed-bean-scope>session</managed-bean-scope>
</managed-bean>
<navigation-rule>
<display-name>login.xhtml</display-name>
<from-view-id>/login.xhtml</from-view-id>
<navigation-case>
<from-outcome>login</from-outcome>
<to-view-id>/welcome.xhtml</to-view-id>
</navigation-case>
</navigation-rule>
</faces-config>web.xml file as follows,
<?xml version="1.0" encoding="UTF-8"?>
<web-app id="richfaces-showcase" version="2.5"
xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
<display-name>richfaces-showcase</display-name><context-param>
<param-name>javax.faces.DISABLE_FACELET_JSF_VIEWHANDLER</param-name>
<param-value>true</param-value>
</context-param><context-param>
<param-name>org.richfaces.enableControlSkinning</param-name>
<param-value>true</param-value>
</context-param>
<context-param>
<param-name>org.richfaces.enableControlSkinningClasses</param-name>
<param-value>false</param-value>
</context-param>
<context-param>
<param-name>org.richfaces.skin</param-name>
<param-value>#{skinBean.skin}</param-value>
</context-param>
<context-param>
<param-name>javax.faces.PROJECT_STAGE</param-name>
<param-value>Development</param-value>
</context-param>
<context-param>
<param-name>javax.faces.STATE_SAVING_METHOD</param-name>
<param-value>server</param-value>
</context-param>
<servlet>
<servlet-name>Faces Servlet</servlet-name>
<servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>Faces Servlet</servlet-name>
<url-pattern>*.jsf</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>Faces Servlet</servlet-name>
<url-pattern>/faces/*</url-pattern>
</servlet-mapping>
<mime-mapping>
<extension>ecss</extension>
<mime-type>text/css</mime-type>
</mime-mapping>
<welcome-file-list>
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
<welcome-file>index.jsp</welcome-file>
<welcome-file>default.html</welcome-file>
<welcome-file>default.htm</welcome-file>
<welcome-file>default.jsp</welcome-file>
</welcome-file-list>
<login-config>
<auth-method>BASIC</auth-method>
</login-config>
</web-app>Please let me know if something is wrong on this.
Regards,
SK
-
4. Re: richfaces 4 example without seam
senthilnz Jan 1, 2011 9:13 AM (in response to senthilnz)I found the problem, thats the tags rich:toolBar and rich:toolBarGroup are renamed as rich:toolbar and rich:toolbarGroup