Setting up Scopes in SharePoint Search Results
The requirement is: When users search from a particular site collection, either the default search result or an advanced search result, should get content ONLY from a list of sites.
Solution? Search Scopes! Search scopes in SharePoint allows users to narrow down the search results based on content sources, web addresses, and metadata. So, I created a scope “Search All Marketing Sites” to include all marketing websites URLs. Now, I’m jumping to setting up scope on Search results directly.
For Default Search Results:
I created a separate search center site, edited the search results page (/SearchCenter/Pages/Results.aspx) Search core results web part properties, Expand the Miscellaneous section and entered the scope.
Pretty straight forward, isn’t it?
How about Advanced Search?
For an advanced search, scopes are not configured in web part properties as in default search results. But, it’s on Site collection’s scope settings. Navigate to top-level site collection’s Site settings >> Search Scopes and then click on “Advanced Search”
This will show all available scopes. Choose the desired scope from the list and click OK.
Once done, All the advanced search results page will be restricted to the specified scope.