You can display the pagetitle, longtitle, summary (introtext), description, menutitle, or alias in either location. I would think one of those could be short enough.
This should give you the count:
([[!ChildCount? &parent=`[[+id]]` ]])
/* ChildCount snippet */
$docId = $modx->getOption('parent', $scriptProperties, '');
$count = $modx->getCount('modResource', array('parent' => $docId));
return $count? $count : '0';
If you want to have a separate landing page. You might be able to do something like this (making the child count a link -- untested):
/* ChildCount snippet */
$landingPageId = 12; // this will always be the same page
$docId = $modx->getOption('parent', $scriptProperties, '');
$count = $modx->getCount('modResource', 'parent' => $docId));
$count = $count? $count : '0';
if (!empty($count)) {
$url = $modx->makeUrl($landingPageId, '', array('parent_id' => $docId));
$output = '<a href="' . $url . '" >' . $count . '</a'>;
} else {
$output = '0';
}
return $output;
Then on your landing page, do this:
[[!GetParent]]
[[!Wayfinder? &startId=`[[+parentId]]` ... ]]
/* GetParent snippet */
$modx->setPlaceholder('parentId', $_GET['parent_id']);
return '';
[ed. note: BobRay last edited this post 10 years, 7 months ago.]