RichFaces 4.0皮肤无法正常工作

时间:2011-05-08 14:04:37

标签: richfaces

我正在测试一个简单的程序,使用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-core-api-4.0.0.Final.jar
4. richfaces-core-impl-4.0.0.Final.jar
5. richfaces-components-api-4.0.0.Final.jar
6. richfaces-components-ui-4.0.0.Final.jar

Tomcat7.0

非常感谢任何建议

4 个答案:

答案 0 :(得分:2)

context参数是:org.richfaces.skin

答案 1 :(得分:0)

这可能是您的解决方案:

RichFaces 4 Requirement

答案 2 :(得分:0)

修改richfaces中的皮肤通常是一场噩梦,Max Katz对参数是正确的:

将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 / classes / META-INF / skins /

如下所述:

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

答案 3 :(得分:0)

* *首先下载blueSky.jar文件并放入lib文件夹。

在web.xml中添加此内容**

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