Re: [xwiki-users] content of a page without includes

2011-10-09 Thread Marius Dumitru Florea
On Fri, Oct 7, 2011 at 10:59 PM, Legeinfo  wrote:
> I want the content of a page ($doc.content) but without the include
> documents.

> Filtering after getting all content is to time consuming.
> Volker

I suppose you are referring to the filtering of the rendered content.
If you can use programming rights then you can get the XDOM tree from
the XWikiDocument wrapped by the script Document api (e.g.
$doc.document.getXDOM()), iterate it, remove all include macros and
then render it. This is best done in Groovy. Note that this solution
is not good if some of your include macro calls are generated from
script macros (Velocity/Groovy) in which case you can't detect/remove
include macros without executing those scripts first, which can be
time consuming as you said.

Hope this helps,
Marius

>
> --
> View this message in context: 
> http://xwiki.475771.n2.nabble.com/content-of-a-page-without-includes-tp6870909p6870909.html
> Sent from the XWiki- Users mailing list archive at Nabble.com.
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users
>
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


[xwiki-users] content of a page without includes

2011-10-07 Thread Legeinfo
I want the content of a page ($doc.content) but without the include
documents.
Filtering after getting all content is to time consuming.
Volker

--
View this message in context: 
http://xwiki.475771.n2.nabble.com/content-of-a-page-without-includes-tp6870909p6870909.html
Sent from the XWiki- Users mailing list archive at Nabble.com.
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users