3 Replies Latest reply on Dec 18, 2006 8:35 PM by fabio.ita04

    Error when installing MyFaces in WEB-INF/lib

    fabio.ita04 Newbie

      Hi,

      I'm getting the following error when placing MyFaces jars in lib project:

      22:58:26,343 INFO [FacesConfigurator] Reading config /WEB-INF/faces-config.xml
      22:58:26,733 ERROR [StartupServletContextListener] Error initializing ServletContext
      java.lang.IllegalArgumentException: Class org.jboss.seam.jsf.SeamApplicationFactory is no javax.faces.application.ApplicationFactory
      


      The error doesn't occurs when myfaces jars are removed. Any help?

      the faces-config:
      <faces-config>
       <application>
       <view-handler>com.sun.facelets.FaceletViewHandler</view-handler>
       </application>
      
       <lifecycle>
       <phase-listener>org.jboss.seam.jsf.SeamPhaseListener</phase-listener>
       </lifecycle>
      </faces-config>
      


      web.xml:
      ...
      <!-- Seam -->
      <listener>
       <listener-class>org.jboss.seam.servlet.SeamListener</listener-class>
      </listener>
      
      <!-- MyFaces -->
      <listener>
       <listener-class>
       org.apache.myfaces.webapp.StartupServletContextListener
       </listener-class>
      </listener>
      
      <context-param>
       <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
       <param-value>.xhtml</param-value>
      </context-param>
      
      <context-param>
       <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
       <param-value>client</param-value>
      </context-param>
      
      <servlet>
       <servlet-name>FacesServlet</servlet-name>
       <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
       <load-on-startup>1</load-on-startup>
      </servlet>
      
      <!-- Faces Servlet Mapping -->
      <servlet-mapping>
       <servlet-name>FacesServlet</servlet-name>
       <url-pattern>*.htm</url-pattern>
      </servlet-mapping>