On Mar 14, 2007, at 8:16 AM, Vincent Massol wrote:


On Mar 14, 2007, at 12:27 AM, Sergiu Dumitriu wrote:



On 3/14/07, Ludovic Dubost <ludovic@xwiki.com> wrote:

One easy way to handle this is to create a page which includes the
childrens using #includeTopic("pagename")

You could add the following script at the end of your parent page

#if($context.action=="pdf")
#set($sql = "where doc.parent='$doc.fullName'")
#foreach($item in $xwiki.searchDocuments($sql))
#includeTopic($item)
#end
#end

Ludovic


Nice. You could put this on xwiki.org FAQs list.

I would also put this in the Code snippet zone.

I wanted to put it in the code zone and I've tried it. The result isn't pretty as all pages are included at the bottom and thus there's no page break.

A better approach is to use http://old.xwiki.org/xwiki/bin/view/Dev/AggregateDocs

This used to work but is now broken somehiw. This is really the best approach. If someone could fix that would be just great and we could put it as a XAR application on xwiki.org

Thanks
-Vincent