JSF 2.0 Mojarra h:head tag
I have a problem when using h:head tag. I am using JSF 2.0 Mojarra's implementation. I try examples just like the ones provided here and here. I always get the same error if I try to use h:head tag. If I use head, the everything is ok.
No problem using other tags, such h:body, h:form...
javax.servlet.ServletException: org/w3c/css/sac/ErrorHandler
javax.faces.webapp.FacesServlet.service(FacesServlet.java:321)
java.lang.NoClassDefFoundError: org/w3c/css/sac/ErrorHandler
org.richfaces.resource.ResourceFactoryImpl.createCompiledCSSResource(ResourceFactoryImpl.java:192)
org.richfaces.resource.ResourceFactoryImpl.createDynamicResource(ResourceFactoryImpl.java:458)
org.richfaces.resource.ResourceFactoryImpl.createResource(ResourceFactoryImpl.java:430)
org.richfaces.resource.ResourceHandlerImpl.createResource(ResourceHandlerImpl.java:268)
org.richfaces.resource.Resource开发者_JS百科HandlerImpl.createResource(ResourceHandlerImpl.java:278)
com.sun.faces.renderkit.html_basic.StylesheetRenderer.encodeEnd(StylesheetRenderer.java:91)
javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:879)
javax.faces.component.UIComponent.encodeAll(UIComponent.java:1650)
com.sun.faces.renderkit.html_basic.HeadRenderer.encodeHeadResources(HeadRenderer.java:101)
com.sun.faces.renderkit.html_basic.HeadRenderer.encodeBegin(HeadRenderer.java:76)
javax.faces.component.UIComponentBase.encodeBegin(UIComponentBase.java:824)
javax.faces.component.UIComponent.encodeAll(UIComponent.java:1641)
javax.faces.component.UIComponent.encodeAll(UIComponent.java:1646)
com.sun.faces.application.view.FaceletViewHandlingStrategy.renderView(FaceletViewHandlingStrategy.java:389)
com.sun.faces.application.view.MultiViewHandler.renderView(MultiViewHandler.java:127)
javax.faces.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:269)
com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:117)
com.sun.faces.lifecycle.Phase.doPhase(Phase.java:97)
com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:135)
javax.faces.webapp.FacesServlet.service(FacesServlet.java:309)
I have a similar problem with this tag, such the mentioned here, but the solution didn't work for me, as it is not exactly the same problem.
It looks like h:head
fails to load some resources for richfaces.
Check if your richfaces jars are in your project's WEB-INF/lib folder.
精彩评论