Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/templates/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Templates 已经找到JSF嵌套ui:insert-Component ID_Templates_Jsf_Primefaces_Facelets - Fatal编程技术网

Templates 已经找到JSF嵌套ui:insert-Component ID

Templates 已经找到JSF嵌套ui:insert-Component ID,templates,jsf,primefaces,facelets,Templates,Jsf,Primefaces,Facelets,我的模板的结构 layout.xhtml <html xmlns="http://www.w3.org/1999/xhtml" xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html" xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:p="http://primefaces.org/ui"> ..

我的模板的结构

layout.xhtml

<html xmlns="http://www.w3.org/1999/xhtml"
     xmlns:f="http://java.sun.com/jsf/core"
     xmlns:h="http://java.sun.com/jsf/html"
     xmlns:ui="http://java.sun.com/jsf/facelets"
     xmlns:p="http://primefaces.org/ui">
...
<h:form id="headerForm" />
...
<ui:insert name="content">Put default content here, if any.</ui:insert>
...
<ui:composition template="/WEB-INF/templates/layout.xhtml"
    xmlns="http://www.w3.org/1999/xhtml"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:ui="http://java.sun.com/jsf/facelets"
    xmlns:p="http://primefaces.org/ui"
    xmlns:c="http://java.sun.com/jstl/core">
<ui:define name="content">
...
<ui:insert name="tabContent">Tab content</ui:insert>
...
</ui:define>
<ui:composition template="/pages/protected/integration/integration.xhtml" 
    xmlns="http://www.w3.org/1999/xhtml"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:ui="http://java.sun.com/jsf/facelets"
    xmlns:p="http://primefaces.org/ui">
<ui:define name="tabContent">
...
</ui:define>
</ui:composition>
这不是HeadePerform的问题。如果我删除它,它将在下一个id为的组件上失败。
如何嵌套这些模板而不出现错误?

哪个JSF impl/version?试过最新版本吗?我正在使用primefaces 3.5。你找到答案了吗?我遇到了类似的问题。不,我没有,我使用了另一种布局来处理xhtml文件。
java.lang.IllegalStateException: Component ID headerForm has already been found in the view.