问题
I need to read a certain attribute from the parent component... but its not working at all,
I tried 2 things to define the attribute using:<ui:param>
and <c:set>
and to read them I tried also 2 things:
<ui:fragment>
and <c:if test>
but no luck Here is the code:
<ui:param name="panelName" value="#{component.parent.attributes.panelName}" />
<c:set var="panelName2" value="{component.parent.attributes.panelName}" scope="view" />
<c:if test="#{panelName == 'abc'}">
anything
</c:if>
<ui:fragment rendered="#{panelName2 == 'abc'}">
Hellooo
</ui:fragment>
I am using JSF 2.2
Could anyone explain why this is happening please
Thanks in advance
来源:https://stackoverflow.com/questions/30412962/cif-and-rendered-is-not-working-at-all