Define scopes for searches

To focus a search on particular locations or content, end users select scopes from the scope list next to the Search box. They can choose All Sites to search all available locations, or select another scope to limit their searches to certain locations or to content marked with particular property values. For example, a query on the This Site scope (if available) will focus a search on the current site and its subsites.

Default scopes such as All Sites and People are defined at the Shared Services Provider level. In addition, an administrator with shared services administration permissions can define custom scopes. Any scope defined at the Shared Services Provider level is shared among all site collections. A site collection administrator can copy a shared scope, modify that copy or use it as-is, and add custom scopes for use within the site collection. Scopes can include other scopes as needed. The site collection administrator also creates scope display groups, and arranges scopes within them, so that site owners can apply them to modify instances of the scope list for the Search boxes on their pages.

 Note   By default, the scopes picker on the Advanced Search page is hidden. However, an administrator with permission to edit the Advanced Search page can modify the Advanced Search Web Part to display its list of scopes, and assign a display group to populate it with scopes.

What do you want to do?


Plan scopes

An administrator defines scopes so that users can focus their searches on particular locations and content. When defining a scope, you can combine location rules with property rules to limit searches as desired. For example, a scope can direct a query to particular sites, or to documents marked with particular property values.

 Note   You can make property values available to searches by using the managed properties feature to which certain content properties are mapped. A list of the managed properties that can be used in scopes appears in the Property Query section of the Create Scope page and the Edit Scope page. For more information, see the later section Add or edit scope rules.

Top of Page Top of Page

Display the View Scopes page

To access the View Scopes page to add or modify scopes and scope display groups, you need to have site collection administrator permissions.

  1. Log on to the home page of your top-level site with site collection administrator permissions.
  2. Click the Site Actions menu, choose Site Settings, and then choose Modify All Site Settings.
  3. On the Site Settings page, in the Site Collection Administration section, click Search scopes. The View Scopes page appears.
  4. To define a new scope, click New Scope, and then follow the steps in the next section, Define a scope.

To edit the rules for an existing scope, click the Add rules link for a scope, then follow the steps in the later section Add or edit scope rules.

To define a custom display group and arrange scopes within it, click New Display Group, and then follow the steps in the later section Configure scope display groups.

Top of Page Top of Page

Define or edit a scope

Scopes make it possible to focus searches on particular locations or materials. An administrator with site collection administrator permissions can copy a shared scope and modify that copy, and can also add custom scopes for use within the site collection.

When adding a custom scope to a site collection, it can be helpful to begin by copying an existing scope such as All sites, and then adding rules that specify locations, content types, or property values. By combining and adjusting multiple rules, you can design scopes for the site collection that provide focused searches tailored to the needs of particular work groups.

  1. Follow the steps in the previous section Display the View Scopes page.
  2. Click New Scope to display the Create Scope page.

Or click the name of an existing scope to display the Scope Properties and Rules page. Then click Change scope settings to display the Edit Scope page.

  1. In the Title box, type a word, name, acronym, or short phrase to display in the Scopes list.
  2. In the Description box, explain the purpose of the scope. This is an optional description, for your reference and for site owners, and is not displayed to end users.
  3. In the Display Groups section, choose where to display this scope, for example Search Dropdown.
  4. In the Target Results Page section, choose whether to display the results from searches of this scope on the default search results page or a different Web page. To use a different search results page, select Specify a different page for searching this scope, and type the Web address for another existing results page in the Target results page box (for example, http://site/subsite/folder/NameOfCustomResultsPage.aspx).
  5. Click OK to save the scope and return to the View Scopes page.

To add scope rules, click Add rules next to the name of the scope, and then follow the steps in the following section Add or edit scope rules.

Top of Page Top of Page

Add or edit scope rules

Scope rules define what content is associated with the scope by specifying locations, properties, or sources of content that are either included in the scope or excluded from the scope.

  1. Follow the steps in the previous section Display the View Scopes page.
  2. In the Update Status column,click the Add rules link next to the name of a scope. The Add Scope Rule page appears.

Or click the name of the scope to display the Scope Properties and Rules page. Then, in the Rules section, click an existing rule to display the Edit Scope Rule page.

  1. In the Scope Rule Type section of the page, choose a type of rule. The choices are Web Address, Property Query, or All Content.
    • To include or exclude a location, choose Web Address and type a location in one of the boxes. (To apply rules to multiple locations, define a separate rule for each location.)

If you type a path in the Folder box (for example, http://site/subsite/folder), the rule will apply only to items located within the folder indicated and its subfolders.

If you type a host name in the Hostname box, the rule will apply to items located anywhere on that host.

If you type a domain name in the Domain or subdomain box, the rule will apply to all items located within that domain.

  • To include or exclude content found by searching on a value assigned to a managed property, choose Property Query. Select a property, and type a value. (To apply rules to multiple properties or values, define a separate rule for each property setting.)

 Note   Managed properties are made available for use in scopes by an administrator with shared services administration permissions.

  • To create a scope that includes anything that is crawled by the content source called Local Office SharePoint Server sites, under Scope Rule Type choose Content Source, and under Content Source select Local Office SharePoint Server sites.
  • To apply a rule to all content from all sites included in the search index, choose All Content.
  1. Select a Behavior to choose how this rule will combine with other rules to define the scope. Choose Include for an "OR" rule, or Exclude for an "AND NOT" rule, or Require for an "AND" rule.
  2. Click OK to apply the rule.

 Note   Search scopes and their rules are compiled on a schedule that is adjusted automatically based on the frequency of past updates. The administrator can also set scope updates to occur manually. A new scope will not appear in a Search Box scope list until after it is compiled the first time.

Top of Page Top of Page

Delete a scope or scope rules

To delete scopes or scope rules, follow the steps in the previous section Display the View Scopes page. Then take the following steps:

Delete a scope

  1. Move the cursor over the name of the scope on the View Scopes page, expand the menu that appears, and choose Delete.
  2. When prompted to confirm, click OK.

Delete scope rules

  1. Move the cursor over the name of a scope on the View Scopes page, expand the menu that appears and choose Edit Properties and Rules. This displays the Scope Properties and Rules page.
  2. To delete an individual scope rule:
    1. Click the name of the rule on the Scope Properties and Rules page.
    2. At the bottom of the Edit Scope Rule page, click Delete.
  3. To delete all rules for a scope:
    1. In the Rules section of the Scope Properties and Rules page, click Delete all rules.

Top of Page Top of Page

Configure scope display groups

Display groups are used to assign scopes to search boxes. For a specific site collection, an administrator with site collection administrator permissions can create a new scope display group and arrange scopes within it, or add scopes to existing display groups. A site owner can then add the display group to the scope list of any Search box in the site, enabling users to do more focused searches.

Create or edit scope display groups

To enable a site owner to change the scopes that are available from the scope list next to a Search box, a site collection administrator can modify existing display groups or create new display groups and arrange scopes within them.

  1. Follow the steps in the previous section Display the View Scopes page.
  2. Click New Display Group to display the Create Scope Display Group page.

Or click the name of an existing display group to display the Edit Scope Display Group page.

  1. On the page selected, type a Title that will help site owners to identify the display group.
  2. Type a Description that explains the scopes provided in this display group, and where these choices might be useful. This is an optional description, for your reference and for site owners, and is not displayed to end users.
  3. In the Scopes section, select the check box next to each scope to include in the display group.
  4. Use the Position from Top lists to adjust the order of scopes within the display group.
  5. In the Default Scope list, choose the scope or scopes that will be displayed in the list, and that will be searched by default if the user does not choose a different scope.
  6. Click OK to finish creating the new display group.

Include a scope in display groups

A scope can be added to existing display groups from the Edit Scope page.

  1. Follow the steps in the previous section Display the View Scopes page.
  2. Click the name of a scope to display the Scope Properties and Rules page.
  3. On the Scope Properties and Rules page, click Change scope settings in the Scope Settings section.
  4. On the Edit Scope page, in the Display Group section, select the display groups that will include this scope, and clear any that will not.
  5. Click OK to save your changes.

Top of Page Top of Page

Assign a display group to a scope list

Add a display group to the scope list of a search box to make the scope available to users of a site.

  1. Log on to the home page of the site.

 Note   An administrator with site collection administrator permissions can modify any Web site within the site collection. A site owner can modify all pages on one site.

  1. Display the page that includes the scope list you want to modify. Expand its Site Actions menu, and choose Edit page.
  2. Move the cursor to the Web Part, expand its Edit menu, and choose Modify Shared Web Part.
  3. Within the Search Box tool pane, click the plus sign (+) to expand the Miscellaneous section.
  4. Scroll to the Scope Display Group box, type the name of the display group that will provide the scopes for this scope list, and then click Apply.
  5. Click OK to close the tool pane.
  6. If your role permits you to make the new scope display group available immediately, click Publish. To have the modified Web Part reviewed first, click Check In to Share Draft.

Top of Page Top of Page

 
 
Applies to:
SharePoint Server 2007