Hi!
My setup:
Netbeans 6.8 + Glassfish v3 + JSF 2.0.2 (also tried 2.0.3 Snapshot of today)
I have following 3 pages:
index.xhtml
<html ...
xmlns:cs="http://java.sun.com/jsf/composite/component">
<h:head>
</h:head>
<h:body>
<cs:comp1>
<f:facet name="header">
HEADER
</f:facet>
</cs:comp1>
</h:body>
</html>
comp1.xhtml
<html ...
xmlns:cs="http://java.sun.com/jsf/composite/component">
<h:head>
</h:head>
<h:body>
<cc:interface>
<cc:facet name="header" />
</cc:interface>
<cc:implementation>
<cs:comp2>
<cc:insertFacet name="header" />
</cs:comp2>
</cc:implementation>
</h:body>
</html>
comp2.xhtml
<html ...
xmlns:cs="http://java.sun.com/jsf/composite/component">
<h:head>
</h:head>
<h:body>
<cc:interface>
<cc:facet name="header" />
</cc:interface>
<cc:implementation>
<cc:renderFacet name="header" />
</cc:implementation>
</h:body>
</html>
In words, I want to pass a facet through a composite component, however it
doesn't work. The text HEADER won't display...
When I change
comp1.xhtml to following:
<h:dataTable>
<cc:insertFacet name="header" />
</h:dataTable>
it
works. The text HEADER will display.
So what I'm doing wrong? Why my composite-component doesn't receive and display the facet and a jsf-standard-component does? JSF Bug??
Btw.: <cc:insertChildren /> alone doesn't fit my requirements, I need facets.
Thanks in advance,
Schober Markus