hi, i have the following code piece:
<h:panelGrid columns="1" id="movieCenterMenu" columnClasses="displayPanel" styleClass="menuStyle">
<h:panelGrid rendered=[b]"not #{MovieCenter.doSearch}" [/b]columns="1" id="[b]tempGrid[/b]" columnClasses="displayPanel" styleClass="menuStyle">
<h:commandLink value="#{bundle.searchLink}" action="#{MovieCenter.search}" id="goSearch" styleClass="headerLinkStyle">
</h:commandLink>
</h:panelGrid>
<h:inputText rendered=[b]"#{MovieCenter.doSearch}" [/b]required="false" id="[b]searchField[/b]"
value="#{MovieCenter.searchMovie}" />
<h:commandButton value="#{bundle.searchButtonLabel}" rendered="#{MovieCenter.doSearch}"
action="#{MovieCenter.display}" id="searchButton" />
<h:dataTable value="#{MovieCenter.movies}" rendered="not #{MovieCenter.doSearch}" first="0"
var="movie" border="1" id="moviesTable">
<h:column>
<f:facet name="header">
<h:outputText value="#{bundle.movieTableHeader}" ></h:outputText>
</f:facet>
<h:commandLink actionListener="#{MovieCenter.showDetailAction}" value="#{movie}">
</h:commandLink>
</h:column>
</h:dataTable>
</h:panelGrid>
As you see, the panal grid “tempGrid” should not display together with the inputText “searchField“, as their rendered attribute values will always controdict!
But when i run it on tomcat, they are displayed together, but the dataTable is working in the right way, that is not displayed together with the inputText “searchField“.
What’s happening?
Best Regards:)