/ Published in: PHP
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
<?php //Switch chunk based on docID and embed snippet call $id = $modx->documentIdentifier; // Ditto parameters $params['startID'] = '39'; $params['display'] = '3'; $params['depth'] = '1'; $params['hideFolders'] = '1'; $params['seeThruUnpub'] = '1'; $params['showPublishedOnly'] = '1'; $params['sortBy'] = 'createdon'; $params['sortDir'] = 'DESC'; $params['tpl'] = 'link_tpl'; if ($pid['id'] == 1750) { $params['start'] = '3'; } $output = $modx->runSnippet('Ditto', $params); return "$output"; ?>