[opencms-dev] Structured Content - Structure Folder

Mario Jäger m.jaeger at alkacon.com
Fri Mar 25 15:32:01 CET 2011


Hi Lynn,

You can create a custom extended folder, which contains a set of jsp 
files per default. You write, that you know how to add a custom 
structured content to the explorer menu. To add a custom extended folder 
to the explorer menu, you have to set the <newresource> node attribute 
"page" in the <explorertype> node to "extendedfolder" instead of 
"structurecontent". And it is to use the "newresource.jsp" instead of 
the "newresource_xmlcontent.jsp" in the "uri" attribute there. One 
example for an extended folder is the "downloadgallery" in the 
opencms-workplace.xml. To create one jsp file in the extended folder per 
default, you have to set the <copy-resources> node in the <resourcetype> 
node then. In the "source" attribute you have to define the original 
source, where the jsp file is copied from. If you set the "type" 
attribute value to "new" a new jsp file is created. If this attribute is 
set to "sibling", then a sibling of the original source is created:

<resourcetypes>
   <type ...>
     <properties>
       ...
     </properties>
     <copy-resources>
       <copy-resource source="/system/modules/mymodule/pages/test1.jsp" 
target="${resource.folder.path}" type="new"/>
       <copy-resource source="/system/modules/mymodule/pages/test2.jsp" 
target="${resource.folder.path}" type="sibling"/>
     </copy-resources>
   </type>
</resourcetypes>

Kind Regards,
Mario.

Am 25.03.2011 14:26, schrieb Lynn Chapman:
>
> I see how to create a custom Structured Content and add it to the Explorer
> menu, but is it possible to create a custom Structured Folder?  I would like
> the user to be able to create a folder which contains a set of jsp files in
> its contents.  I thought I could do that by creating a custom "thing" the
> user choosed.  Structured content doesn't seem to work - it doesn't create a
> folder.
>
> Lynn


-- 
-------------------
Mario Jäger

Visit OpenCms Days 2011 Conference and Expo
May 9 to May 10 2011 in Cologne, Germany
http://www.opencms-days.org

Alkacon Software GmbH  - The OpenCms Experts
http://www.alkacon.com - http://www.opencms.org



More information about the opencms-dev mailing list