Reputation: 510
There is a multidomain setup (domains next to each other on the same level), each domain has their own search page and configuration. I've tried...
plugin.tx_indexedsearch.settings.rootPidList = 3
...to get the search results limited to the domains pagetree only. But as soon as using rootPidList, there are no results at all any more. Then i've tried...
plugin.tx_indexedsearch.settings.defaultOptions.sections = rl1_3
...and this seems to work correctly to limit the results to the pagetree (below page id 3).
So what is "rootPidList" ment to be used for?
Upvotes: 0
Views: 363
Reputation: 3747
According to the comment in the code (typo3/sysext/indexed_search/Classes/Controller/SearchController.php, Line 232):
Setting the list of root PIDs for the search. Notice, these page IDs MUST have a TypoScript template with root flag on them!
Basically this list is used to select on the "rl0" field and page ids are registered as "rl0" only if a TypoScript template record with root flag is there.
This happens AFTER the use of $this->searchRootPageIdList above because the above will then fetch the menu for the CURRENT site - regardless of this kind of searching here. Thus a general search will lookup in the WHOLE database while a specific section search will take the current sections.
In a multi domain setup we have set rootPidList
to the overall root page (in this case id=457).
defaultOptions.sections
is set like this:
defaultOptions.sections=rl{$customer_theme.search.level}_{$customer_theme.root}
{$customer_theme.search.level}
is set to 1 or 2 depending on the availability of more than one language per country.
{$customer_theme.root}
is the root page (marked by the root page flag).
e.g. for Indonesia (english) we use level = 2 and root = 12947.
Upvotes: 1