2 Replies Latest reply on Jun 18, 2007 10:31 AM by Jonathan Shin

    Richfaces SKIN issue

    Jonathan Shin Newbie

      SKIN was working fine but sometimes, I lose the SKIN and can't get it back. However, since yesterday the SKIN doesn't work at all. I don't believe I have changed any configuration files. By the way, I'm using ie 6.0.

      ajax4jsf-1.1.1-SNAPSHOT
      oscache-2.3.2
      richfaces-3.0.1-SNAPSHOT
      trinidad-impl-1.0.0-incubating

      Thanks.

      web.xml
      <?xml version="1.0" ?>
      <web-app 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"
       version="2.4">
      
       <!-- Ajax4jsf (must come first!) -->
      
       <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>
       <url-pattern>*.seam</url-pattern>
       </filter-mapping>
      
       <!-- Not used, as we've integrated Trinidad -->
       <!-- <context-param>
       <param-name>org.ajax4jsf.VIEW_HANDLERS</param-name>
       <param-value>org.jboss.seam.ui.facelet.SeamFaceletViewHandler</param-value>
       </context-param>-->
      
      
       <context-param>
       <param-name>org.ajax4jsf.SKIN</param-name>
       <param-value>blueSky</param-value>
       </context-param>
      
      
       <!-- Seam -->
      
       <listener>
       <listener-class>
       org.jboss.seam.servlet.SeamListener
       </listener-class>
       </listener>
      
       <filter>
       <filter-name>Seam Filter</filter-name>
       <filter-class>org.jboss.seam.web.SeamFilter</filter-class>
       </filter>
      
       <filter-mapping>
       <filter-name>Seam Filter</filter-name>
       <url-pattern>/*</url-pattern>
       </filter-mapping>
      
       <servlet>
       <servlet-name>Seam Resource Servlet</servlet-name>
       <servlet-class>
       org.jboss.seam.servlet.ResourceServlet
       </servlet-class>
       </servlet>
      
       <servlet-mapping>
       <servlet-name>Seam Resource Servlet</servlet-name>
       <url-pattern>/seam/resource/*</url-pattern>
       </servlet-mapping>
      
       <!-- MyFaces -->
      
       <listener>
       <listener-class>
       org.apache.myfaces.webapp.StartupServletContextListener
       </listener-class>
       </listener>
      
       <!-- Facelets development mode (disable in production) -->
      
       <context-param>
       <param-name>facelets.DEVELOPMENT</param-name>
       <param-value>true</param-value>
       </context-param>
      
       <!-- JSF -->
      
       <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>
      
       <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>*.seam</url-pattern>
       </servlet-mapping>
      
       <security-constraint>
       <display-name>Restrict raw XHTML Documents</display-name>
       <web-resource-collection>
       <web-resource-name>XHTML</web-resource-name>
       <url-pattern>*.xhtml</url-pattern>
       </web-resource-collection>
       <auth-constraint>
       <role-name>NONE</role-name>
       </auth-constraint>
       </security-constraint>
      
       <!-- Trinidad -->
      
       <context-param>
       <param-name>
       org.apache.myfaces.trinidad.ALTERNATE_VIEW_HANDLER
       </param-name>
       <param-value>
       org.jboss.seam.ui.facelet.SeamFaceletViewHandler
       </param-value>
       </context-param>
      
       <context-param>
       <param-name>
       org.apache.myfaces.trinidad.CHANGE_PERSISTENCE
       </param-name>
       <param-value>session</param-value>
       </context-param>
      
       <filter>
       <filter-name>Trinidad</filter-name>
       <filter-class>
       org.apache.myfaces.trinidad.webapp.TrinidadFilter
       </filter-class>
       </filter>
      
       <filter-mapping>
       <filter-name>Trinidad</filter-name>
       <url-pattern>*.seam</url-pattern>
       </filter-mapping>
      
       <servlet>
       <servlet-name>Trinidad Resources</servlet-name>
       <servlet-class>
       org.apache.myfaces.trinidad.webapp.ResourceServlet
       </servlet-class>
       </servlet>
      
       <servlet-mapping>
       <servlet-name>Trinidad Resources</servlet-name>
       <url-pattern>/adf/*</url-pattern>
       </servlet-mapping>
      
      </web-app>
      

      view file
      <!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
       "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
      
      <ui:composition xmlns="http://www.w3.org/1999/xhtml"
       xmlns:s="http://jboss.com/products/seam/taglib"
       xmlns:ui="http://java.sun.com/jsf/facelets"
       xmlns:f="http://java.sun.com/jsf/core"
       xmlns:h="http://java.sun.com/jsf/html"
       xmlns:a="https://ajax4jsf.dev.java.net/ajax"
       xmlns:rich="http://richfaces.ajax4jsf.org/rich"
       template="layout/template.xhtml">
      
      <ui:define name="body">
      
       <h:messages globalOnly="true" styleClass="message" id="globalMessages"/>
      
       <h:form id="address" styleClass="edit">
      
       <rich:panel>
       <f:facet name="header">Edit Address</f:facet>
      
       <s:decorate id="addressIdDecoration" template="layout/edit.xhtml">
       <ui:define name="label">addressId</ui:define>
       <h:inputText id="addressId"
       required="true"
       disabled="#{addressHome.managed}"
       value="#{addressHome.instance.addressId}">
       <a:support event="onblur" reRender="addressIdDecoration"/>
       </h:inputText>
       </s:decorate>
      
       <s:decorate id="address1Decoration" template="layout/edit.xhtml">
       <ui:define name="label">address1</ui:define>
       <h:inputText id="address1"
       size="50"
       maxlength="50"
       value="#{addressHome.instance.address1}">
       <a:support event="onblur" reRender="address1Decoration"/>
       </h:inputText>
       </s:decorate>
      
       <s:decorate id="address2Decoration" template="layout/edit.xhtml">
       <ui:define name="label">address2</ui:define>
       <h:inputText id="address2"
       size="50"
       maxlength="50"
       value="#{addressHome.instance.address2}">
       <a:support event="onblur" reRender="address2Decoration"/>
       </h:inputText>
       </s:decorate>
      
       <s:decorate id="address3Decoration" template="layout/edit.xhtml">
       <ui:define name="label">address3</ui:define>
       <h:inputText id="address3"
       size="50"
       maxlength="50"
       value="#{addressHome.instance.address3}">
       <a:support event="onblur" reRender="address3Decoration"/>
       </h:inputText>
       </s:decorate>
      
       <s:decorate id="cityDecoration" template="layout/edit.xhtml">
       <ui:define name="label">city</ui:define>
       <h:inputText id="city"
       size="30"
       maxlength="30"
       value="#{addressHome.instance.city}">
       <a:support event="onblur" reRender="cityDecoration"/>
       </h:inputText>
       </s:decorate>
      
       <s:decorate id="zipCodeDecoration" template="layout/edit.xhtml">
       <ui:define name="label">zipCode</ui:define>
       <h:inputText id="zipCode"
       size="10"
       maxlength="10"
       value="#{addressHome.instance.zipCode}">
       <a:support event="onblur" reRender="zipCodeDecoration"/>
       </h:inputText>
       </s:decorate>
      
       <div style="clear:both">
       <span class="required">*</span>
       required fields
       </div>
      
       </rich:panel>
      
       <div class="actionButtons">
      
       <h:commandButton id="save"
       value="Save"
       action="#{addressHome.persist}"
       disabled="#{!addressHome.wired}"
       rendered="#{!addressHome.managed}"/>
      
       <h:commandButton id="update"
       value="Save"
       action="#{addressHome.update}"
       rendered="#{addressHome.managed}"/>
      
       <h:commandButton id="delete"
       value="Delete"
       action="#{addressHome.remove}"
       rendered="#{addressHome.managed}"/>
      
       <s:button id="done"
       value="Done"
       propagation="end"
       view="/Address.xhtml"
       rendered="#{addressHome.managed}"/>
      
       <s:button id="cancel"
       value="Cancel"
       propagation="end"
       view="/#{empty addressFrom ? 'AddressList' : addressFrom}.xhtml"
       rendered="#{!addressHome.managed}"/>
      
       </div>
       </h:form>
      
      <rich:tabPanel switchType="ajax">
      
       <rich:tab label="state">
       <div class="association" id="stateParent">
      
       <h:outputText value="No state"
       rendered="#{addressHome.instance.state == null}"/>
      
       <rich:dataTable var="state"
       value="#{addressHome.instance.state}"
       rendered="#{addressHome.instance.state != null}"
       rowClasses="rvgRowOne,rvgRowTwo"
       id="stateTable">
       <h:column>
       <f:facet name="header">stateId</f:facet>
       #{state.stateId}
       </h:column>
       <h:column>
       <f:facet name="header">name</f:facet>
       #{state.name}
       </h:column>
       <h:column>
       <f:facet name="header">action</f:facet>
       <s:link view="/State.xhtml"
       id="viewstate"
       value="View"
       propagation="none">
       <f:param name="stateStateId"
       value="#{state.stateId}"/>
       </s:link>
       </h:column>
       </rich:dataTable>
      
       <div class="actionButtons">
       <s:button value="Select state"
       view="/StateList.xhtml">
       <f:param name="from" value="AddressEdit"/>
       </s:button>
       </div>
      
       </div>
       </rich:tab>
      
       <rich:tab label="country">
       <div class="association" id="countryParent">
      
       <h:outputText value="No country"
       rendered="#{addressHome.instance.country == null}"/>
      
       <rich:dataTable var="country"
       value="#{addressHome.instance.country}"
       rendered="#{addressHome.instance.country != null}"
       rowClasses="rvgRowOne,rvgRowTwo"
       id="countryTable">
       <h:column>
       <f:facet name="header">countryId</f:facet>
       #{country.countryId}
       </h:column>
       <h:column>
       <f:facet name="header">name</f:facet>
       #{country.name}
       </h:column>
       <h:column>
       <f:facet name="header">action</f:facet>
       <s:link view="/Country.xhtml"
       id="viewcountry"
       value="View"
       propagation="none">
       <f:param name="countryCountryId"
       value="#{country.countryId}"/>
       </s:link>
       </h:column>
       </rich:dataTable>
      
       <div class="actionButtons">
       <s:button value="Select country"
       view="/CountryList.xhtml">
       <f:param name="from" value="AddressEdit"/>
       </s:button>
       </div>
      
       </div>
       </rich:tab>
      
       <rich:tab label="companies">
       <div class="association" id="companiesChildren">
      
       <h:outputText value="No companies"
       rendered="#{empty addressHome.companies}"/>
      
       <rich:dataTable value="#{addressHome.companies}"
       var="company"
       rendered="#{not empty addressHome.companies}"
       rowClasses="rvgRowOne,rvgRowTwo"
       id="companiesTable">
       <h:column>
       <f:facet name="header">companyId</f:facet>
       <h:outputText value="#{company.companyId}"/>
       </h:column>
       <h:column>
       <f:facet name="header">name</f:facet>
       <h:outputText value="#{company.name}"/>
       </h:column>
       <h:column>
       <f:facet name="header">webSite</f:facet>
       <h:outputText value="#{company.webSite}"/>
       </h:column>
       <h:column>
       <f:facet name="header">action</f:facet>
       <s:link view="/Company.xhtml"
       id="selectcompany"
       value="Select"
       propagation="none">
       <f:param name="companyCompanyId"
       value="#{company.companyId}"/>
       <f:param name="companyFrom" value="Address"/>
       </s:link>
       </h:column>
       </rich:dataTable>
      
       </div>
      
       <f:subview rendered="#{addressHome.managed}" id="companies">
       <div class="actionButtons">
       <s:button id="addcompany"
       value="Add company"
       view="/CompanyEdit.xhtml"
       propagation="none">
       <f:param name="addressAddressId"
       value="#{addressHome.instance.addressId}"/>
       <f:param name="companyFrom" value="Address"/>
       </s:button>
       </div>
       </f:subview>
       </rich:tab>
      </rich:tabPanel>
      </ui:define>
      
      </ui:composition>