开发者

Resource Config in JSF framework

Do anyone know how to configure resource-config.xml in JSF application.

For a new enhancement i have started configuring resource-config.xml, i tried placing it under META-INF folder, WEB-INF/classes, java source root directory. Neither one worked out for me. Resource config file is not recognized even if it is in the build path.

Can anyone guide me in configuring t开发者_如何学JAVAhe same?

Thanks in advance.!

<?xml version="1.0" encoding="UTF-8"?>
<resource-config>
    <resource class="org.richfaces.renderkit.html.images.GrowlBackground">
        <name>org.richfaces.renderkit.html.images.GrowlBackground</name>
    </resource>
    <resource class="org.richfaces.renderkit.html.images.GrowlCloseButton">
        <name>org.richfaces.renderkit.html.images.GrowlCloseButton</name>
    </resource>
    <resource>
        <name>org/richfaces/renderkit/html/images/info.png</name>
        <path>org/richfaces/renderkit/html/images/info.png</path>
    </resource>
    <resource>
        <name>org/richfaces/renderkit/html/css/jquery.gritter.xcss</name>
        <path>org/richfaces/renderkit/html/css/jquery.gritter.xcss</path>
    </resource>
    <resource>
        <name>org/richfaces/renderkit/html/scripts/growl.js</name>
        <path>org/richfaces/renderkit/html/scripts/growl.js</path>
    </resource>
    <resource>
        <name>org/richfaces/renderkit/html/images/error.png</name>
        <path>org/richfaces/renderkit/html/images/error.png</path>
    </resource>
    <resource>
        <name>org/richfaces/renderkit/html/scripts/jquery/jquery.js</name>
        <path>org/richfaces/renderkit/html/scripts/jquery/jquery.js</path>
    </resource>
    <resource>
        <name>org/richfaces/renderkit/html/scripts/jquery.gritter.js</name>
        <path>org/richfaces/renderkit/html/scripts/jquery.gritter.js</path>
    </resource>
    <resource>
        <name>org/richfaces/renderkit/html/images/warn.png</name>
        <path>org/richfaces/renderkit/html/images/warn.png</path>
    </resource>
    <resource>
        <name>org/richfaces/renderkit/html/images/fatal.png</name>
        <path>org/richfaces/renderkit/html/images/fatal.png</path>
    </resource>
</resource-config>


It should be in META-INF.

Attached is a link to CDK - Component Development Kit (CDK) which is a sub-project of RichFaces

there is a description of the configuration and path of resource-config.xml, used in development. hopefully it will shed light on your problem.

could you please post resource-config.xml? maybe there is an issue there?

--- Edit

If you develop with richfaces maybe try src/main/config/resources as suggested at Developer Guide section 4?

--- Edit

another source that might help registering components with rich

Hope this helps.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜