[opencms-dev] Displaying properties within <cms:contentload>

Christian Steinert christian_steinert at web.de
Mon Aug 14 12:08:03 CEST 2006


Christian Steinert schrieb:
> Hi List,
> 
> I have desparately tried to find out, how to display properties of files
> in a <cms:contentload ...> loop.
> 
> I am using resourcetype xmlpage, I do not want to create my own
> structured xml type, if this is not necessary.
> 
> I do a loop over my resources and try to display the Title property of
> each resource:
> 
> <cms:contentload collector="allInFolderNavPos"
> param="/faq/faq_${number}.html|xmlpage" editable="true">
> 
>   <cms:contentshow element="${property.Title}"/>
> 
> </cms:contentload>
> 
> ___
> 
> But the I do not see the titles of the files that I loop over.
> Instead I only see the title of the index page itself which contains
> this code.
> 
> I have tried different things:
> <cms:contentshow element="Title"/> doesn't work, because there is no XML
> element called Title
> <cms:contentshow element="property.Title"/> also doesn't work
> 
> 
> Is there any way to use cms:contentload / cms:contentshow for accessing
> file properties? Or can I somehow get the name of the current
> contentload-file into a scriptlet-variable?
> 
> 
> Thanks and Regards
> Christian

P.S. I have also tried
<cms:property name="title" file="${opencms.filename}" />

But this also doesn't work. It seems that cms:property does not evaluate
the macro and instead looks for a file called "${opencms.filename}".

c.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3269 bytes
Desc: S/MIME Cryptographic Signature
URL: <https://webmail.opencms.org/pipermail/opencms-dev/attachments/20060814/91f6e0e6/attachment.bin>


More information about the opencms-dev mailing list