Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Raghav 34 posts 103 karma points
    Feb 03, 2016 @ 09:12
    Raghav
    0

    Examine- Allow to search only node types for a specific Content Item

    Hi,

    I have a structure where in we need to enable content search for example for AboutUs and FAQ page. These will be 2 separate tabs on the page and the user can choose to search specific to each one of them. But since they are using the same document type (i.e buildingBlockItem) for content as custom picker how can I ensure that the results I get is specific to that section. Please note that AboutUS and FAQ in itself are separate document types but their content is mapped to common document type (i.e buildingblockitem) and hence am not sure if including node type option will help.

    Any help is greatly appreciated.

    Thanks Raghav

  • Mike Chambers 636 posts 1253 karma points c-trib
    Feb 03, 2016 @ 17:58
    Mike Chambers
    100

    You could create two custom indexes, with the start nodes set as your separate nodes and then run the query against the relevant one?

    There is a "IndexParentId" paramater that you can use.

    <IndexSet SetName="CWSIndexSet"
                  IndexPath="~/App_Data/CWSIndexSetTest"
                  IndexParentId="-1">
    ....
    </IndexSet>
    

    documentation [https://our.umbraco.org/documentation/Reference/Config/ExamineSettings/]

Please Sign in or register to post replies

Write your reply to:

Draft