Hi all,
How does one get the resource parent menutitle? [[*parent]] renders the resource’s parent ID but I need to render the menutitle - what syntax should be used?
Thanks
dubbs
You could use the getField snippet, but here’s a custom snippet that should work:
create a snippet called getMenuTitle:
<?php
$resource = $modx->getObject('modResource', $id);
return $resource->get('menutitle');
?>
Then use this where you want the menutitle:
[[!getMenuTitle? &id=`[[*parent]]`]]