Re: PrettyFaces and Tomahawk/MyFaces – JSF2 – Error JSF1064

Splash Forums PrettyFaces Users PrettyFaces and Tomahawk/MyFaces – JSF2 – Error JSF1064 Re: PrettyFaces and Tomahawk/MyFaces – JSF2 – Error JSF1064

#20998

Could you please try to register the PrettyFilter exactly like shown in the documentation? It is important to use the correct dispatcher settings:

<filter>
<filter-name>Pretty Filter</filter-name>
<filter-class>com.ocpsoft.pretty.PrettyFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>Pretty Filter</filter-name>
<url-pattern>/*</url-pattern>
<dispatcher>FORWARD</dispatcher>
<dispatcher>REQUEST</dispatcher>
<dispatcher>ERROR</dispatcher>
</filter-mapping>

Also make sure to use the same dispatcher entries when configuring the MyFaces Extensions Filter. Something like this:

<filter>
<filter-name>MyFacesExtensionsFilter</filter-name>
<filter-class>org.apache.myfaces.webapp.filter.ExtensionsFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>MyFacesExtensionsFilter</filter-name>
<servlet-name>Faces Servlet</servlet-name>
<dispatcher>FORWARD</dispatcher>
<dispatcher>REQUEST</dispatcher>
<dispatcher>ERROR</dispatcher>
</filter-mapping>
<filter-mapping>
<filter-name>MyFacesExtensionsFilter</filter-name>
<url-pattern>/faces/myFacesExtensionResource/*</url-pattern>
<dispatcher>FORWARD</dispatcher>
<dispatcher>REQUEST</dispatcher>
<dispatcher>ERROR</dispatcher>
</filter-mapping>

See:

http://ocpsoft.com/docs/prettyfaces/3.2.0/en-US/html/FAQ.html

This is important because the MyFaces filter must accept forwarded requests from PrettyFaces.