-
1. Re: Nested composite compounds not working in combination with ui:include
valentinx Mar 20, 2012 7:56 AM (in response to valentinx)we found a workaround by adding the composite namespace (in our case xmlns:lib="...") to the composite:implemenation tag
like
<composite:interface>
<composite:attribute name="bean" required="true" />
</composite:interface>
<composite:implementation xmlns:composites="http://java.sun.com/jsf/composite/composites">
.......
</composite:implemenation>
-
2. Re: Nested composite compounds not working in combination with ui:include
xportebois Mar 20, 2012 8:19 AM (in response to valentinx)We get the exact same problem, but cannot find any workaround. Yours works here too.
Does anyone know if it's a real bug or a needed modification?
-
3. Re: Nested composite compounds not working in combination with ui:include
jmighion Jun 12, 2012 11:02 AM (in response to valentinx)I had this same problem and the solution I found was to change the declaration of the file you're including. So instead of :
<head>
<!-- some css imports-->
</head>
<body>
<ui:include src="some.xhmtl>
<lib:test/>
</bod>
not working EVEN if the some.xhtml is like
<html
xmlns="http://www.w3.org/1999/xhtml"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:c="http://java.sun.com/jsp/jstl/core"
><ui:composition></ui:composition></html>
Change the some.xhtml to :
<ui:composition
xmlns="http://www.w3.org/1999/xhtml"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:c="http://java.sun.com/jsp/jstl/core"
>
the rest of the body
</ui:composition>
The bug for us was that the html declaration was being ignored since there was already an html declaration higher in our app, so the upgrade to EAP 6 beta 2 made us change this to the proper declaration. This way, you dont need to add the xmlns to the tag surrounding your composite component.
Hope this helps!