[opencms-dev] cms:vfs get content of page element

Jonathan Woods jonathan.woods at scintillance.com
Fri Jul 24 19:06:26 CEST 2009


And (maybe stating the obvious) don't forget you can always cut out the
middle man and dive straight into <% java %> if the  JSP API isn't clear.  I
felt very liberated when I lost all shame about doing that!

> -----Original Message-----
> From: opencms-dev-bounces at opencms.org 
> [mailto:opencms-dev-bounces at opencms.org] On Behalf Of 
> a.westermann at alkacon.com
> Sent: 24 July 2009 14:29
> To: The OpenCms mailing list
> Subject: Re: [opencms-dev] cms:vfs get content of page element
> 
> Hi Yves,
> 
> I'd try
> 
> <c:set var="myvar"><cms:include file="" element="/en/op/start.html" 
> element="content"/></c:set>
> 
> Then you could use:
> 
> ${myvar}
> 
> somewhere else.
> 
> Kind Regards,
> Achim.
> 
> -------------------
> Achim Westermann
> 
> Alkacon Software GmbH  - The OpenCms Experts 
> http://www.alkacon.com - http://www.opencms.org
> 
> 
> 
> 
> Yves Glodt wrote:
> > Hello,
> > 
> > is there a way usiing the powerful cms:vfs to get the 
> content of a page element?
> > 
> > Somehow like (guessing, this does not work):
> > ${cms:vfs(pageContext).readResource['/en/op/start.html'].contents}
> > or
> > 
> ${cms:vfs(pageContext).readXml['/en/op/start.html'].value("content")}
> > 
> > 
> > I need to get the html of a page element to pass it to a taglib...
> > 
> > Best regards,
> > Yves
> > 
> > _______________________________________________
> > This mail is sent to you from the opencms-dev mailing list 
> To change 
> > your list options, or to unsubscribe from the list, please visit 
> > http://lists.opencms.org/mailman/listinfo/opencms-dev
> 
> _______________________________________________
> This mail is sent to you from the opencms-dev mailing list To 
> change your list options, or to unsubscribe from the list, 
> please visit http://lists.opencms.org/mailman/listinfo/opencms-dev




More information about the opencms-dev mailing list