So I’m trying to figure out how to simply get the Child Count of documents using Ditto. I’ve looked around the forums and I see that there are some examples using Wayfinder which really are not working so well with my situation, but I’m not seeing anything with Ditto.
Essentially I have a ditto call like so:
[!Ditto? &parents=`[*id*]` &tpl=`class_tpl` &sortBy=`menuindex` &sortDir=`ASC`!]
Then the coding for the tpl is:
<h2>[+pagetitle+]</h2>
<p>XXX Classes</p>
[+summary+]
I need the "XXX" to be replaced with the number of children for that particular container. The hierarchy is like so:
- Courses
-- Course Title 1
--- Class 1
--- Class 2
--- Class 3
-- Course Title 2
--- Class 1
--- Class 2
--- Class 3
Anyone had any experience with this? Thanks!