Thanks for your reaction Mark,
This code is being outputted when I removed the &resource property and enabled debugging:
<strong>Resource Query</strong>:<br />SELECT `id`, `menutitle`, `longtitle`, `introtext` FROM `modx_site_content` AS `modResource` WHERE ( ( LOWER(`modResource`.`longtitle`) LIKE '%gemeente woerkum%' OR LOWER(`modResource`.`longtitle`) LIKE '%onze%' OR LOWER(`modResource`.`longtitle`) LIKE '%diensten%' ) AND ( `modResource`.`id` != 3 AND `modResource`.`context_key` IN ('web') ) AND `modResource`.`id` NOT IN (0) AND `modResource`.`parent` IN (16,30) AND `modResource`.`published` = 1 ) ORDER BY createdon desc LIMIT 125 <br/><strong>TV Query</strong>:<br />SELECT modTemplateVarResource.id AS tvid, Resource.id, `value`, `name`, Resource.menutitle AS menutitle, Resource.longtitle AS longtitle, Resource.introtext AS introtext FROM `modx_site_tmplvar_contentvalues` AS `modTemplateVarResource` JOIN `modx_site_tmplvars` `TemplateVar` ON `modTemplateVarResource`.`tmplvarid` = `TemplateVar`.`id` JOIN `modx_site_content` `Resource` ON `modTemplateVarResource`.`contentid` = `Resource`.`id` WHERE ( ( `modTemplateVarResource`.`contentid` != 3 AND `Resource`.`context_key` IN ('web') AND `Resource`.`id` NOT IN (0) AND `Resource`.`parent` IN ('16','30') AND `Resource`.`published` = '1' AND `TemplateVar`.`name` IN ('tags') ) AND (LOWER(value) LIKE '%gemeente woerkum%' OR LOWER(value) LIKE '%onze%' OR LOWER(value) LIKE '%diensten%') ) ORDER BY createdon desc LIMIT 125 <br/><strong>Config:</strong>array(28) {
["base_bath"]=>
string(54) "/home/searchbv/public_html/core/components/getrelated/"
["core_path"]=>
string(54) "/home/searchbv/public_html/core/components/getrelated/"
["model_path"]=>
string(60) "/home/searchbv/public_html/core/components/getrelated/model/"
["elements_path"]=>
string(63) "/home/searchbv/public_html/core/components/getrelated/elements/"
["resource"]=>
string(7) "current"
["fields"]=>
string(21) "tv.tags:1,longtitle:2"
["returnFields"]=>
array(3) {
[0]=>
string(9) "menutitle"
[1]=>
string(9) "longtitle"
[2]=>
string(9) "introtext"
}
["returnTVs"]=>
array(0) {
}
["parents"]=>
array(2) {
[0]=>
string(2) "16"
[1]=>
string(2) "30"
}
["parentsDepth"]=>
int(10)
["contexts"]=>
array(1) {
[0]=>
string(3) "web"
}
["includeUnpublished"]=>
string(0) ""
["includeHidden"]=>
bool(true)
["exclude"]=>
array(1) {
[0]=>
string(0) ""
}
["limit"]=>
string(1) "1"
["fieldSample"]=>
int(125)
["fieldSort"]=>
string(9) "createdon"
["fieldSortDir"]=>
string(4) "desc"
["tvSample"]=>
int(125)
["tvSort"]=>
string(9) "createdon"
["tvSortDir"]=>
string(4) "desc"
["tplOuter"]=>
string(24) "tRelatedCasesOuterWidget"
["tplRow"]=>
string(19) "tRelatedCasesWidget"
["noResults"]=>
string(23) "Geen gerelateerde cases"
["toPlaceholder"]=>
string(0) ""
["rowSeparator"]=>
string(1) "
"
["defaultWeight"]=>
int(5)
["debug"]=>
string(1) "1"
}
<br/><strong>Fields:</strong>array(1) {
[0]=>
string(9) "longtitle"
}
<br/><strong>TVs:</strong>array(1) {
[0]=>
string(4) "tags"
}
<br/><strong>Match Data:</strong>array(3) {
[0]=>
string(16) "gemeente woerkum"
[1]=>
string(4) "onze"
[2]=>
string(8) "diensten"
}
<br/><strong>All Related Resources:</strong>array(0) {
}
When I remove the &parents property the plugin is working but I don't want other resources to be found as the ones in that particular container.