Hi Mark,
Please find the image of the documetation with the "==" marked, as an attachment.
Also, I am calling ditto as under...
//snippet name: ap_listRelated1
//snippet call: [[ap_listRelated]]
//Display related list of stories based on information from TV = "ap_tags" and functionality of ditto snippet call.
//get value of current doc id
$currentID = $modx->documentObject['id'];
$valueTags = $modx->getTemplateVarOutput('ap_tags', $currentID, 1);
if(isset($valueTags['ap_tags']) && $valueTags['ap_tags'] !='') {
$snippetName= 'ap_ditto';
$snippetParams=array('mode'=>"production",
'startID'=>11,
'summarize'=>10,
'hideFolders'=>1,
'tpl'=>"ap_listRelated",
'sortBy'=>"pub_date",
'tagData'=>"tvap_tags",
'tagDelimiter'=>", ",
'tags'=>$valueTags['ap_tags'],
'hiddenTVs'=>"ap_tags",
'filter'=>"id,$currentID,=",
'emptyText'=>"No related content available at this time.");
//initialise $outstring
$outstring='';
//build $outstring
$outstring.='<div class="sub-story cf">';
$outstring.='<h1 class="t1"><span>Related Content</span></h1>';
$outstring.='<ul>';
$outstring.=$modx->runSnippet($snippetName, $snippetParams);
$outstring.='</ul>';
$outstring.='</div> <!-- /relatedOutput -->';
$outstring.='<hr />';
//-- return listing
return $outstring;
}
else {}
The above code works as expected. But, when I try and add one more TV to the hiddenTVs e.g. ap_bodyID, the code stops to function and returns "No related content available at this time." when there are more related content.
Actually, I would like to add ap_bodyID to the hiddenTVs and then filter (i.e. show) only documents whose ap_bodyID==story.
Hope I have been able to explain myself clearly. Please feel free to ask for any more information from my end.