6 Replies Latest reply on Jun 19, 2009 8:00 AM by Ilya Shaikovsky

    Default Styles/CSS not loaded - Tomcat 6

    Carlos Marcos Newbie

      Hi,

      i've an application builded in hibernate+spring+richfaces, and i've a problem with richfaces styles when I deploy the application in tomcat 6.

      All works fine, but the richfaces elements are loaded without css 'default' styles. For example, i put a calendar element and it works fine, but it is shown without styles (colors, aligns, etc).

      if i put the css reference that are generated in final html in my browser, it returns me a blank page (<link href="http://localhost:8010/presentation-layer-richfaces/a4j/s/3_3_1.GAorg/richfaces/renderkit/html/css/basic_classes.xcss/DATB/eAF7sqpgb-jyGdIAFrMEaw__.jsf); if i try the same with javascript reference, it works fine.

      this is my web.xml file:

      
      <?xml version="1.0" encoding="UTF-8"?>
      <web-app id="person" version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
       <display-name>person</display-name>
      
      
       <context-param>
       <param-name>javax.faces.DEFAULT_SUFFIX
       </param-name>
       <param-value>.jsp</param-value>
       </context-param>
       <context-param>
       <param-name>facelets.REFRESH_PERIOD
       </param-name>
       <param-value>2</param-value>
       </context-param>
       <context-param>
       <param-name>facelets.DEVELOPMENT</param-name>
       <param-value>true</param-value>
       </context-param>
       <context-param>
       <param-name>javax.faces.STATE_SAVING_METHOD
       </param-name>
       <param-value>server</param-value>
       </context-param>
       <context-param>
       <param-name>org.richfaces.SKIN</param-name>
       <param-value>blueSky</param-value>
       </context-param>
      
      
       <listener>
       <listener-class>org.springframework.web.context.ContextLoaderListener
       </listener-class>
       </listener>
       <listener>
       <listener-class>
       org.springframework.web.context.request.RequestContextListener
       </listener-class>
       </listener>
      
       <filter>
       <display-name>Ajax4jsf Filter</display-name>
       <filter-name>ajax4jsf</filter-name>
       <filter-class>org.ajax4jsf.Filter</filter-class>
       </filter>
       <filter-mapping>
       <filter-name>ajax4jsf</filter-name>
       <servlet-name>Faces Servlet</servlet-name>
       <dispatcher>REQUEST</dispatcher>
       <dispatcher>FORWARD</dispatcher>
       <dispatcher>INCLUDE</dispatcher>
       </filter-mapping>
       <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>
       <login-config>
       <auth-method>BASIC</auth-method>
       </login-config>
      </web-app>
      


      If i deploy de thame application in jboss server, it works perfect.

      anyone can help me?

      thanks in advance,