Plone的4.3安裝在C:\目錄Plone43與位於C site.zcml:\ Plone43 \配件\實例\等\ site.zcmlPlone的設置靜態圖像目錄
所有我想要做的就是設置一個目錄,我可以把一些圖像或資源,並能夠訪問它們使用URL像http://wiki.mycompany.net:8080/++resources++PROJECTNAME/images/someimage.png
我已經激活了plone.resource 1.0.2,但不知道現在放置任何圖像或如何配置它。我聽過人們在談論zcml,但我不知道他們在談論什麼zcml文件。
我在site.zcml中添加了這一行,然後plone站點不會出現,所以我不得不刪除它。
請問有人可以幫我配置一個靜態資源文件夾嗎?如果可能的話,我可以直接在site.zcml中配置一個全局的。
當前site.zcml看起來是這樣的:
<configure
xmlns="http://namespaces.zope.org/zope"
xmlns:meta="http://namespaces.zope.org/meta"
xmlns:five="http://namespaces.zope.org/five">
<include package="Products.Five" />
<meta:redefinePermission from="zope2.Public" to="zope.Public" />
<!-- Load the meta -->
<include files="package-includes/*-meta.zcml" />
<five:loadProducts file="meta.zcml"/>
<!-- Load the configuration -->
<include files="package-includes/*-configure.zcml" />
<five:loadProducts />
<!-- Load the configuration overrides-->
<includeOverrides files="package-includes/*-overrides.zcml" />
<five:loadProductsOverrides />
<securityPolicy
component="AccessControl.security.SecurityPolicy" />
</configure>
Plone人做出了一個慣用的假設:你所做的任何自定義或集成都是通過附加包完成的。下面的答案應該爲創建一個附加組件提供一些指導,目的是包含靜態資源。 – sdupton