6 Replies Latest reply on Oct 10, 2007 10:52 AM by Dmitry Demyankov

    rich:modalPanel dissappearing after click

    Richard Fanning Newbie

      Hi,

      For some reason my modalPanel keeps appearing (after i click the link) & then immediately disappearing in all browsers??

      I am using RichFaces3.1.0, JSF 1.2, Facelets 1.2.1.

      Any ideas?

      Thanks

      Rich

      <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
      <html xmlns="http://www.w3.org/1999/xhtml"
       xmlns:ui="http://java.sun.com/jsf/facelets"
       xmlns:h="http://java.sun.com/jsf/html"
       xmlns:f="http://java.sun.com/jsf/core"
       xmlns:a4j="http://richfaces.org/a4j"
       xmlns:rich="http://richfaces.org/rich">
      <body>
      <f:view>
      
       <h:form>
       <h:commandLink value="Logout" onclick="javascript:Richfaces.showModalPanel('logoutPanel',{width:250, top:200})" />
       </h:form>
       <rich:modalPanel id="logoutPanel" minHeight="200" minWidth="250" height="200" width="250" zindex="20">
       <f:facet name="header">
       <h:outputText value="Logout" />
       </f:facet>
       <p>
       <h:outputText value="Are you sure you want to logout"/>
      
       <h:form>
       <h:panelGrid columns="2" cellpadding="20px">
       <h:commandButton value="Yes" />
       <h:commandButton value="No" onclick="javascript:Richfaces.hideModalPanel('logoutPanel')"/>
       </h:panelGrid>
       </h:form>
       </p>
       </rich:modalPanel>
      </f:view>
      </body>
      </html>