Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I am trying to setup some specific crawl rules , I have a local site that is being indexed

http://mylocalsite

and I only want to index files under a certain location such as http://mylocalsite/forms/ but sharepoint will index and follow the links on the pages giving me search results outside of what I want to index

How can I setup crawl rules to specifically limit the search results to a single directory http://mylocalsite/forms/

share|improve this question
add comment

2 Answers

up vote 1 down vote accepted

Create two rules:

1) http://mylocalsite/forms/* with an "Include" (And any other options you want)

2) http://mylocalsite* with an "Exclude" (And any other options you want)

Only one crawl rule will ever be active for content, and it will activate based on how close it is to the top of the list. All content inside the "forms" directory will therefore hit the first rule and go through, while all other content will be blocked.

share|improve this answer
add comment

Depending on your situation, you could also set up a scope with a "required" rule of "http://mylocalsite/forms/"

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.