3 Replies Latest reply on Nov 21, 2008 5:16 AM by gan lee

    script & css url is not correct in richfaces 3.2

    gan lee Newbie

      Hi,
      I migrated richfaces from 3.1.4 to 3.2; but met a very strange problem.
      In 3.1.4 the generated script url is like:

      /fs-mmc/faces/a4j_3_1_4.GAorg.ajax4jsf.javascript.PrototypeScript

      the fs-mmc is my webapp's context-path
      But in both 3.2.2ga, 3.2.2SR1, the script url is like:
      *.jsf/faces/a4j/g/3_2_2.GAorg.ajax4jsf.javascript.PrototypeScript

      And the same to css url.

      the web.xml is as below:
      <?xml version="1.0" encoding="UTF-8"?>
      <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
       xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
       id="WebApp_ID" version="2.5">
       <display-name>fs-mmc</display-name>
       <description>fs mmc</description>
       <!--
       JSF options using SUN RI or MyFaces
       http://publib.boulder.ibm.com/infocenter/wasinfo/v7r0/index.jsp?topic=/com.ibm.websphere.express.doc/info/exp/ae/rweb_jsfengine.html
       -->
       <context-param>
       <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
       <param-value>client</param-value>
       </context-param>
       <context-param>
       <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
       <param-value>.xhtml</param-value>
       </context-param>
       <context-param>
       <param-name>javax.faces.CONFIG_FILES</param-name>
       <param-value>/WEB-INF/faces-config.xml</param-value>
       </context-param>
       <!-- JSF options using SUN RI -->
       <context-param>
       <description>
       Set this flag to true if you want the JavaServer Faces
       Reference Implementation to validate the XML in your
       faces-config.xml resources against the DTD. Default
       value is false.
       </description>
       <param-name>com.sun.faces.validateXml</param-name>
       <param-value>true</param-value>
       </context-param>
       <context-param>
       <description>
       Set this flag to true if you want the JavaServer Faces
       Reference Implementation to verify that all of the application
       objects you have configured (components, converters,
       renderers, and validators) can be successfully created.
       Default value is false.
       </description>
       <param-name>com.sun.faces.verifyObjects</param-name>
       <param-value>true</param-value>
       </context-param>
       <!--
       Facelets Initialization Parameters
       file:///D:/devlib/facelets-1.1.14/docs/dev/docbook.html#config-webapp
       -->
       <context-param>
       <param-name>facelets.DEVELOPMENT</param-name>
       <param-value>true</param-value>
       </context-param>
       <context-param>
       <param-name>facelets.BUFFER_SIZE</param-name>
       <param-value>8192</param-value>
       </context-param>
       <context-param>
       <param-name>facelets.REFRESH_PERIOD</param-name>
       <param-value>2</param-value>
       </context-param>
       <!--
       RichFaces Initialization Parameters
       file:///D:/devlib/richfaces-ui-3.2.2.SR1/docs/userguide/en/html/SettingsForDifferentEnvironments.html#WebApplicationDescriptorParameters
       -->
       <context-param>
       <param-name>org.richfaces.SKIN</param-name>
       <param-value>classic</param-value>
       </context-param>
       <context-param>
       <param-name>org.ajax4jsf.VIEW_HANDLERS</param-name>
       <param-value>com.sun.facelets.FaceletViewHandler</param-value>
       </context-param>
       <!-- RichFaces Filter -->
       <filter>
       <display-name>RichFaces Filter</display-name>
       <filter-name>richfaces</filter-name>
       <filter-class>org.ajax4jsf.Filter</filter-class>
       <init-param>
       <param-name>enable-cache</param-name>
       <param-value>false</param-value>
       </init-param>
       </filter>
       <filter-mapping>
       <filter-name>richfaces</filter-name>
       <servlet-name>Faces Servlet</servlet-name>
       <dispatcher>FORWARD</dispatcher>
       <dispatcher>REQUEST</dispatcher>
       <dispatcher>INCLUDE</dispatcher>
       </filter-mapping>
       <!-- JSF Servlet -->
       <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>
       <url-pattern>/faces/*</url-pattern>
       </servlet-mapping>
       <welcome-file-list>
       <welcome-file>index.html</welcome-file>
       <welcome-file>index.htm</welcome-file>
       <welcome-file>index.jsp</welcome-file>
       <welcome-file>default.html</welcome-file>
       <welcome-file>default.htm</welcome-file>
       <welcome-file>default.jsp</welcome-file>
       </welcome-file-list>
      </web-app>


      Any replies are very thankful!