metadata tag not working in jsf

六眼飞鱼酱① 提交于 2019-12-02 09:45:34
skuntsel

Your major mistake is that JSP is a deprecated view technology and is clearly a wrong tool for new projects. It has been succeeded by facelets, which is the default view technology for JSF 2.0+ projects.

Some tags, namely the ones used by you like <f:metadata> and <f:viewParam> are not available in JSPs (see sections 10.4.1.3 and 2.5.5 of JSF 2.2 specification (JSR-344) respectively).

The solution is straightforward: switch to facelets as the view technology.

It is also requested to switch to using the new namespaces that have been proposed since JSF 2.2, namely http://java.sun.com should now become http://xmlns.jcp.org (see Preface, page 8 of JSF 2.2 specification (JSR-344)), though both namespaces will work. Also see BalusC's comment to this answer and BalusC's answer to a similar question.

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