This content has been marked as final.
Show 7 replies
-
1. Re: problems with modal panel
nbelaevski Jul 7, 2009 6:22 AM (in response to hrbaer)Covered in the project FAQ: http://www.jboss.org/file-access/default/members/jbossrichfaces/freezone/docs/devguide/en/faq/faq.html#d0e417
-
2. Re: problems with modal panel
hrbaer Jul 7, 2009 7:13 AM (in response to hrbaer)"nbelaevski" wrote:
Covered in the project FAQ: http://www.jboss.org/file-access/default/members/jbossrichfaces/freezone/docs/devguide/en/faq/faq.html#d0e417
I'm completely lost.
Isn't that example exactly what I did? -
3. Re: problems with modal panel
giftsam Jul 8, 2009 2:22 AM (in response to hrbaer)Hi,
If you want to perform action for modal panel, you must have a separate form inside it. In this case, the panel must be declared outside of the other form on the same page. the preceding code snippet would be helpful.<html> <head></head> <body> <f:view> <h:form> </h:form> <rich:modalPanel id="kommentar"> <f:facet name="header"> <h:outputText value="What ever..." /> </f:facet> <f:facet name="controls"> <h:commandLink value="Close" style="cursor:pointer" onclick="Richfaces.hideModalPanel('kommentar')" /> </f:facet> <p> <br>blabla:<br><br> <h:inputTextarea value="#{mb.newKommentar}" cols="40" rows="5" /> </p> <h:form> <h:commandButton value="Kommentar erfassen" actionListener="#{mb.anzeigeKontakt}" /> <h:commandLink actionListener="#{mb.anzeigeKontakt}" value="Test" /> </h:form> </rich:modalPanel> </f:view> </body> </html>
-
4. Re: problems with modal panel
hrbaer Jul 8, 2009 4:19 AM (in response to hrbaer)"giftsam" wrote:
...In this case, the panel must be declared outside of the other form on the same page.
omg, I placed it right befor the closing form ... thought It would be outside.
Thank you! -
5. Re: problems with modal panel
hrbaer Jul 10, 2009 5:49 AM (in response to hrbaer)Hi,
I'm still having some problems to get the value of the entered text in my modal panel.<html> <head></head> <body> <f:view> <h:form> </h:form> <rich:modalPanel id="kommentar"> <f:facet name="header"> <h:outputText value="What ever..." /> </f:facet> <f:facet name="controls"> <h:commandLink value="Close" style="cursor:pointer" onclick="Richfaces.hideModalPanel('kommentar')" /> </f:facet> <p> <br>blabla:<br><br> <h:inputTextarea value="#{mb.newKommentar}" cols="40" rows="5" /> </p> <h:form> <h:commandButton value="Kommentar erfassen" actionListener="#{mb.addComment}" /> </h:form> </rich:modalPanel> </f:view> </body> </html>
I reach the method addComent by clicking on the button but the value newKommentar is always null. Is it because the modal panel isn't nested inside the form? -
6. Re: problems with modal panel
ilya_shaikovsky Jul 10, 2009 5:58 AM (in response to hrbaer)no. Modal should not be nested inside a form. But inputTextArea should.
-
7. Re: problems with modal panel
hrbaer Jul 10, 2009 8:37 AM (in response to hrbaer)"ilya_shaikovsky" wrote:
no. Modal should not be nested inside a form. But inputTextArea should.
Thanks!