{{velocity}}
#if($doc.name=="WebHome")
#set($tree = $xwiki.doctree.getSpaceDocumentTree($doc.web))
#else
#set($tree = $xwiki.doctree.getDocumentTree($doc))
#end
#set($depths=["", "*", "**", "***",
"****", "*****", "******",
"*******",
"********"])
#foreach($leaf in $tree)
#if($leaf.depth <= 8 && ($leaf.depth != 0 ||
$doc.name=="WebHome"))
$depths.get($leaf.depth)
[[$xwiki.getDocument($leaf.fullName).getDisplayTitle()>>$leaf.fullName
]]
#end
#end
{{/velocity}}
Ok so that's actually a velocity script and not a macro or any kind
(the {{velocity}} itself is a macro that you use to write a script) :)
Hard to tell you what's exactly wrong, you will have to debug a bit.
For example are you sure $xwiki.doctree plugin is still here ? Maybe
you forgot to put it in your new instance.
I know that this as is just is a velocity sniplet, but I implemented it as a
macro: I added a MacroClass to a specific page and I configed it that way
that I could call it by {{childrenpagetree/}}. But as mentioned, this
doesn't work anymore. What can I have destroyed while upgrading from 3.5 to
4.0?
By the way: Macros in general do work. We have recently developed another
macro (in 4.0) which also works.
Thanks and best regards,
Moritz