I have this code, but <h:commandButton> don´t works, anyone knows why?
<rich:modalPanel id="panel" width="750" height="300"> <f:facet name="header"> <h:panelGroup> <h:outputText value="Dados"></h:outputText> </h:panelGroup> </f:facet> <f:facet name="controls"> <h:panelGroup> <h:graphicImage value="/close.png" style="cursor:pointer" id="hidelink"/> <rich:componentControl for="panel" attachTo="hidelink" operation="hide" event="onclick"/> </h:panelGroup> </f:facet> <table id="mainDataTable"> <tr> <td> <h:outputText value="Confira os dados: " style="font-style: italic; font-size: 1.5em"/> </td> </tr><br/> <br/> <tr> <td> <h:outputText value="Nome:" style="font-style: italic"/></td> <td> <h:outputText id="textnome" value="#{ususario.nome}"/> </td></tr> <tr> <td> Sobrenome</td> <td> <h:outputText id="textsobrenome" value="#{ususario.sobrenome}"/> </td></tr> <tr> <td> CPF </td> <td><h:outputText id="textcpf" value="#{ususario.cpf}"/></td></tr> <tr> <td> Endereço </td> <td> <h:outputText id="textendereco" value="#{ususario.endereco}"/></td> </tr> <tr> <td> <h:commandButton id="inser" value="Inserir Dados" action="#{ususario.inserir}" /> </td> <td> </td> </tr> </table> </rich:modalPanel>
in our developer guide this is marked as important note ;)
modal panel should have form inside. And certainly in this case should not be placed inside some external form.