3 Replies Latest reply on Jun 30, 2009 6:40 AM by Ilya Shaikovsky

    XML Parsing Error: undefined entity, Ajax-Response

    Markus Eisele Newbie

      Hi,

      I have a quite simple problem. I am trying to update a selectbox using a4j:support.

      <h:selectOneMenu id="test" value="#{test.somedata}"
       valueChangeListener="#{test.valueChanged}" immediate="true">
       <f:selectItems value="#{test.somedataItems}" />
       <a4j:support event="onchange"
       reRender="resultList,test" />
      </h:selectOneMenu>


      The SelectItems are db backed and contain UTF-8 Characters (e.g. é, does not display correct in the this post. ). The response contains the HTML Entities (
      &eacute;
      ) and I get a parsing error from the JS engine in the browser.

      error[10:37:31,169]: Error parsing XML
      error[10:37:31,169]: Parse Error: XML Parsing Error: Reference to undefined entity 'eacute'.
      Location: Line Number 0, Column 0:^

      Any ideas what I could do to solve this?

      Thanks in advance,
      Markus

        • 1. Re: XML Parsing Error: undefined entity, Ajax-Response
          Nick Belaevski Master

          Hi Markus,

          Please post your web.xml file.

          • 2. Re: XML Parsing Error: undefined entity, Ajax-Response
            Markus Eisele Newbie

            Hi nbelaevski,

            here it is:

            <context-param>
             <param-name>org.richfaces.SKIN</param-name>
             <param-value>blueSky</param-value>
             </context-param>
            
             <context-param>
             <param-name>org.richfaces.CONTROL_SKINNING</param-name>
             <param-value>enable</param-value>
             </context-param>
            
             <context-param>
             <param-name>org.ajax4jsf.xmlparser.ORDER</param-name>
             <param-value>NONE,NEKO,TIDY</param-value>
             </context-param>
            
             <context-param>
             <param-name>org.ajax4jsf.xmlparser.NEKO</param-name>
             <param-value>\.xhtml</param-value>
             </context-param>
            
            
             <filter>
             <display-name>RichFaces Filter</display-name>
             <filter-name>richfaces</filter-name>
             <filter-class>org.ajax4jsf.Filter</filter-class>
             </filter>
            
            
            
             <filter-mapping>
             <filter-name>richfaces</filter-name>
             <servlet-name>Faces Servlet</servlet-name>
             <dispatcher>REQUEST</dispatcher>
             <dispatcher>FORWARD</dispatcher>
             <dispatcher>INCLUDE</dispatcher>
             </filter-mapping>
            
            
            
             <context-param>
             <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
             <param-value>.xhtml</param-value>
             </context-param>
            
             <!-- Select JSF State Saving Mode -->
             <context-param>
             <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
             <param-value>server</param-value>
             </context-param>
            
             <context-param>
             <param-name>javax.faces.CONFIG_FILES</param-name>
             <param-value>/WEB-INF/faces-config.xml, /WEB-INF/faces-beans.xml, /WEB-INF/faces-navigation.xml</param-value>
             </context-param>
            
             <!-- Special Debug Output for Development -->
             <context-param>
             <param-name>facelets.DEVELOPMENT</param-name>
             <param-value>true</param-value>
             </context-param>
            
             <!-- Optional JSF-RI Parameters to Help Debug -->
             <context-param>
             <param-name>com.sun.faces.validateXml</param-name>
             <param-value>true</param-value>
             </context-param>
             <context-param>
             <param-name>com.sun.faces.verifyObjects</param-name>
             <param-value>false</param-value>
             </context-param>
            
             <servlet>
             <servlet-name>Faces Servlet</servlet-name>
             <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
             <load-on-startup>1</load-on-startup>
             </servlet>
             <servlet-mapping>
             <servlet-name>Faces Servlet</servlet-name>
             <url-pattern>*.jsf</url-pattern>
             </servlet-mapping>


            • 3. Re: XML Parsing Error: undefined entity, Ajax-Response
              Ilya Shaikovsky Master

              It seems you should try to use Neko or Tidy parser instead of none.