2011-05-08 77 views
0

我正在測試一個簡單的程序,使用richfaces 4.0顯示皮膚顏色,但它不工作。RichFaces 4.0皮膚不工作

<?xml version="1.0" encoding="UTF-8"?> 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
<html xmlns="http://www.w3.org/1999/xhtml" 
     xmlns:f="http://java.sun.com/jsf/core" 
     xmlns:h="http://java.sun.com/jsf/html" 
     xmlns:a4j="http://richfaces.org/a4j" 
     xmlns:rich="http://richfaces.org/rich"> 

    <h:head> 
     <title>RichFaces Greeter</title> 
    </h:head> 

    <h:body> 
     <f:view> 
      <h:form> 
       <rich:panel style="width:60%"> 
       <rich:tabPanel switchType="ajax" width="70%" headerAlignment="left" style="background-color:#B5CEFD;width:100%"> 
        <rich:tab label="Profile" name="Profile">Profile Content</rich:tab> 
        <rich:tab label="Enquiry" name="Enquiry"> 
         <rich:tabPanel width="70%" headerAlignment="left"> 
          <rich:tab label="Valuation" name="Portfolio Valuation">Portfolio Valuation</rich:tab> 
          <rich:tab label="Transactions" name="Transactions">Transactions</rich:tab> 
          <rich:tab label="Ror" name="Rate of Return">Rate of Return</rich:tab> 
         </rich:tabPanel> 
        </rich:tab> 
        <rich:tab label="LdapMgmt" name="LdapMgmt">Ldap User Management</rich:tab> 
        <rich:tab label="AccessMgmt" name="AccessMgmt">Account Access Management</rich:tab> 
       </rich:tabPanel> 
       </rich:panel> 
      </h:form> 
     </f:view> 
    </h:body> 
</html> 


<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> 

這些是庫:
1. JSF的api.jar文件(mojara2-0-4)
2. JSF的impl.jar中(mojara2-0- 4)
3. RichFaces的核-API-4.0.0.Final.jar
4. RichFaces的核 - IMPL-4.0.0.Final.jar
5. RichFaces的組件-API-4.0.0。 Final.jar
6. RichFaces的組件-UI-4.0.0.Final.jar

Tomcat7.0

任何意見是非常讚賞

回答

2

上下文參數是:org.richfaces.skin

0

修改RichFaces的皮膚是噩夢一般,最大卡茨是對有關參數:

改變org.richfaces.SKIN到org.richfaces.skin應該幫助

,你也可以在看其他參數:

http://docs.jboss.org/richfaces/latest_4_1_X/javadoc/richfaces-core-impl/org/richfaces/application/CoreConfiguration.Items.html

這裏就是終於成功了爲我工作:

放的.properties文件到:/的WebContent/WEB-INF /班/ META-INF /毛皮/

中的說明:

https://community.jboss.org/thread/162295

0

* *先下載blueSky.jar文件,並放在lib文件夾。

在web.xml中添加此containt **

<context-param> 
<param-name>org.richfaces.SKIN</param-name> 
<param-value>blueSky</param-value> 
</context-param>