Richfaces 4 components don't render

梦想的初衷 提交于 2019-12-01 06:23:17

the source code I get from browser is identical

In other words, the FacesServlet wasn't called and was therefore not able to do its job. That can only mean that the request URL did not match the URL pattern of the FacesServlet as definied in web.xml. Perhaps you opened the page by http://localhost:8080/bisis-please-work/somepage.xhtml instead of by http://localhost:8080/bisis-please-work/somepage.jsf which would match <url-pattern>*.jsf</url-pattern> as you've definied in web.xml.

Alternatively, you can also replace *.jsf by *.xhtml so that you don't need to fiddle with URLs anymore and also don't need to worry about the client being able to see the raw JSF source code. The only disadvantage is that you won't be able to serve "plain vanilla" XHTML files without invoking the FacesServlet, but that shouldn't matter, those files should have the .html extension anyway.

I had the same problem, but with a different root cause. For me, richfaces components, in particular the rich:tabPanel, were not rendering because there were plain html tags in the page.

<head>...</head>

instead of

<h:head>...</h:head>

caused the rich:tabPanel to not display at all.

Using plain html body tags caused the tabs to render, but not be clickable.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!