This is what I have ....
Clicking on 'hello' navigates to newPage whereas clicking on 'world'
does not navigate to newPage. Any ideas...
Thanks,
M
Detail.xhtml
<s:decorate id="button" template="layout/edit.xhtml"> <div class="navBar"> <h:commandButton value="Hello" action="#{test.hello}" rendered="#{test.renderHello}" view="/test2.xhtml"/> <h:commandButton value="World" action="#{test.world}" rendered="#{test.renderWorld}" view="/test2.xhtml"/> </div> </s:decorate>
@Name("test") public class Test { public boolean getRenderHello() { return true; } public boolean getRenderWorld() { return true; } public void hello() { System.out.println("hello"); } public void world() { System.out.println("world"); } }
<page....> <navigation from-action="#{test.hello}"> <redirect view-id="/newPage.xhtml"/> </navigation> <navigation from-action="#{test.world}"> <redirect view-id="/newPage.xhtml"/> </navigation> </page>