3 Replies Latest reply on Jul 24, 2007 7:28 AM by sgthawk

    XHTMLModalPanel

    sgthawk

      I have a strange problem, i converted my JSPX Site to MIME-Type:application/xhtml+xml Doctype:Transitional.It doens not work anymore and i get an js error "panel.modalPanel has no properties". If i switch back to content-Type "text/html", it works!What's the cause?

        • 1. Re: XHTMLModalPanel

          What exactly the Richfaces version do you use?

          • 2. Re: XHTMLModalPanel
            sgthawk

            Hello Sergey,
            I use the latest official version.Here is my jspx:

            <?xml version="1.0" encoding="utf-8"?>
            <html xmlns="http://www.w3.org/1999/xhtml"
             xmlns:jsp="http://java.sun.com/JSP/Page"
             xmlns:f="http://java.sun.com/jsf/core"
             xmlns:h="http://java.sun.com/jsf/html"
             xmlns:a4j="https://ajax4jsf.dev.java.net/ajax"
             xmlns:rich="http://richfaces.ajax4jsf.org/rich"
             xmlns:svg="http://www.w3.org/2000/svg">
             <jsp:output doctype-root-element="html"
             doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
             doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" />
             <jsp:directive.page contentType="application/xhtml+xml" />
             <head>
             <title>Willkommen im Login</title>
             </head>
             <f:view>
             <body onload="javascript:Richfaces.showModalPanel('testPanel')">
             <!-- a4j:loadStyle src="/css/login" />
             <h:graphicImage value="/images/meac2000.jpg" />
             <rich:modalPanel id="modalLogin" width="270" height="130" >
             <f:facet name="header">
             <h:outputText value="Anmeldung" />
             </f:facet>
             <h:form id="modal" >
             <h:panelGrid columns="2" border="0">
             <h:outputLabel for="user" value="Login-Name:" />
             <h:inputText id="user" value="#{login.username}" maxlength="15"/>
             <h:outputLabel for="pass" value="Passwort:" />
             <h:inputSecret id="pass" maxlength="10" value="#{login.password}" />
             <h:commandButton value="Anmelden" action="#{login.doLogin}"
             actionListener="#{plant.createPlantConfig}" />
             <h:messages />
             </h:panelGrid>
             </h:form>
             </rich:modalPanel-->
             </body>
             </f:view>
             </html>


            • 3. Re: XHTMLModalPanel
              sgthawk

              Update:
              That was really strange, it did not have anything to do with Richfaces library.The Myfaces library 1.1.5 which i used with Tomcat 5.5.23 was the fault. I switched to JSF 1.2 RI and Tomacat 6.0.13 and now it works with the content-type set to application/xhtml+xml, i cannot say why, but the Myfaces Implementation seems to be faulty....