Copied to clipboard

Flag this post as spam?

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

  • Griffi 1 post 81 karma points
    Jun 07, 2018 @ 10:23

    Has anyone found an easy way to exclude pages from examin index.

    I tried exclude node but with no luck. I have hidden area but these pages show up in search results.


  • Andy Felton 141 posts 410 karma points c-trib
    Jun 07, 2018 @ 17:08
    Andy Felton

    Hi Griffi,

    Are you using the standard method within Umbraco to protect an area of the site? If so by default the ExternalIndexer should exclude protected and unpublished pages:

        <!-- default external indexer, which excludes protected and unpublished pages-->
        <add name="ExternalIndexer" type="UmbracoExamine.UmbracoContentIndexer, UmbracoExamine"/>

    If you want these pages to show for certain members this blog may provide some help.

    Hope that helps Andy

  • Andy Felton 141 posts 410 karma points c-trib
    Jun 09, 2018 @ 07:55
    Andy Felton


    I've just done a little more investigation on this and it seems that the indexer correctly removes the node marked as protected but then indexes it's children.

    Not quite what I expected!


  • Andy Felton 141 posts 410 karma points c-trib
    Jun 09, 2018 @ 08:48
    Andy Felton


    Using the standard indexer does work but it appears as if you have to republish the folder of the now private content.

    I've checked the External Index with Luke and after switching the node to private and republishing none of the child nodes are in the examine index!

    Hope that helps Andy

  • Nigel Wilson 917 posts 2005 karma points
    Jun 07, 2018 @ 19:50
    Nigel Wilson

    Hi Griffi

    The only way I have achieved this is to include the umbracoNaviHide (or some other property on the document type) in the search index, and then iterate through the search results and exclude any results that have the property set.

    Not sure if there is a better way, but it works.


  • Dan Diplo 1463 posts 5630 karma points MVP 3x c-trib
    Jun 07, 2018 @ 21:28
    Dan Diplo

    In ExamineIndex.config (in /config/) you can exclude specific document types and fields from being indexed eg.

      <IndexSet SetName="MyIndexSet"
          <add Name="heading" />
          <add Name="summary" />
          <add Name="bodyText" />
          <add Name="metaDescription" />
          <add Name="metaKeywords" />
          <add Name="doNotIndex" />
          <add Name="secretDocument" />

    This won't index any document types with an alias of secretDocument

    If you want more complex exclusions you'll need to write your own indexer - this isn't as hard as it seems as you can inherit from the base UmbracoContentIndexer and then override the AddDocument method. Within there you can add custom logic to decide what is indexed or not.

Please Sign in or register to post replies

Write your reply to: