Throughout the years, I've seen people achieving this in multiple ways (most commonly excluding *.aspx using crawl rules), but the right way of doing it is creating a scope and using either the IsDocument or contentclass properties.
(...)
To set up a scope using the IsDocument, in SharePoint 2010:
- Open Central Administration
- Go to Manage service applications, in the Application Management section
- Go to your Search Service Application
- Go to Scopes, in the Queries and Results section
- Create a new scope
- Configure the scope details appropriately (not relevant to our scenario) and click OK
- Back to the Scopes page, hover over the newly created scope and in the contextual menu select Edit Properties and Rules
- The Scope Rule Type will be Property Query
- In the Property Query, select IsDocument and value 1
- The Behavior is Require
- Click OK and the configuration is done!
With the IsDocument property, the definition is broader. For instance, pages and images will be included. You pretty much letting SharePoint decide for you, on what is or isn't considered a document.
Both option are suitable and the choice will ultimately depend on the specific requirement you have, there's no right or wrong.
No comments:
Post a Comment