This content has been marked as final.
Show 7 replies
-
1. Re: display faces message on modalPanel?
ilya_shaikovsky May 19, 2008 9:04 AM (in response to lmk)yes. Just place the messages in modal Panel. And check in oncomplete if the FacesContext.maximumSeverity not equals null - show the panel
-
2. Re: display faces message on modalPanel?
lmk May 19, 2008 10:34 AM (in response to lmk)"ilya_shaikovsky" wrote:
yes. Just place the messages in modal Panel. And check in oncomplete if the FacesContext.maximumSeverity not equals null - show the panel
I dont found how to use EL boolean expression and javscript code to show modalPanel.
So i look at the modalPanel doc and i found a useful parameter : showWhenRendered
the code below works:<rich:modalPanel id="_panel_error" headerClass="tab_title" height="110" width="550" showWhenRendered="#{facesContext.maximumSeverity !=null}"> <f:facet name="header">Login errors</f:facet> <f:facet name="controls"> <h:graphicImage value="/images/close.png" style="cursor:pointer" onclick="Richfaces.hideModalPanel('_panel_error')" /> </f:facet> <rich:panel style="border:0;height:100px"> <rich:message for="validate_login" layout="list"> <f:facet name="header"> <h:outputText value="Entered Login informations:"></h:outputText> </f:facet> <f:facet name="errorMarker"> <h:graphicImage value="/images/error.gif" /> </f:facet> </rich:message> </rich:panel> </rich:modalPanel>
-
3. Re: display faces message on modalPanel?
djkrite May 19, 2008 11:22 AM (in response to lmk)Thanks for this. Another good to know item. This panel always appears in the upper left hand corner on firefox. How can I get this panel centered?
-
4. Re: display faces message on modalPanel?
djkrite May 19, 2008 11:24 AM (in response to lmk)Same code gets centered in ie.
-
5. Re: display faces message on modalPanel?
lmk May 19, 2008 11:29 AM (in response to lmk)try
autosized="true"
-
6. Re: display faces message on modalPanel?
djkrite May 19, 2008 12:06 PM (in response to lmk)still a no go in firefox:
<rich:modalPanel id="error" autosized="true" showWhenRendered="#{facesContext.maximumSeverity !=null}"> <f:facet name="header">Message:</f:facet> <f:facet name="controls"> <h:graphicImage value="/images/close.png" style="cursor:pointer" onclick="Richfaces.hideModalPanel('error')" /> </f:facet> <table class="blank" style="font-size: 10pt; white-space: nowrap"> <nobr> <rich:messages> <f:facet name="errorMarker"> <h:graphicImage value="/images/error.gif" /> </f:facet> <f:facet name="warnMarker"> <h:graphicImage value="/images/info.gif" /> </f:facet> <f:facet name="infoMarker"> <h:graphicImage value="/images/passed.gif" /> </f:facet> </rich:messages> </nobr> </table> </rich:modalPanel>