Reader Level:
ARTICLE

Creating a Scope and Tab for MOSS Search Center

Posted by Rifaqat Ali Articles | SharePoint 2010 February 17, 2010
Making the scope available, and then the creation of not just one, but two tabs in Search Center along with ASPX pages. Before beginning, this article assumes that you already have the Shared Services Provider (SSP) properly set up and that you have a "Search Center with Tabs" site available in your portal.
  • 0
  • 0
  • 6198

Making the scope available, and then the creation of not just one, but two tabs in Search Center along with ASPX pages. Before beginning, this article assumes that you already have the Shared Services Provider (SSP) properly set up and that you have a "Search Center with Tabs" site available in your portal. For my example, I'll create a tab designed to search a specific document library that contains Best Practices.

Note:  This article does not cover creating an "Advanced Search" capability - just a simple keyword search.

Create the Shared Scope

The first step is to create a Shared Scope that will target the document library. This Shared Scope will be set up in the Shared Services Provider using the following steps:

  1. On the home page of the Shared Services Administration site, click "Search Settings"
     
  2. On the Search Settings page, click "View Scopes"
     
  3. On the View Scopes page, click the "New" button
     
  4. On the Create Scope page

    - Enter Best Practices in the Title field
    - Leave the results page using the default page, you'll change that later
    - Click the OK button.
     
  5. On the View Scopes page, locate the new scope and click the "Add Rules" link
     
  6. On the Add Scope Rule page

    - Set the Scope Rule Type to "Web Address"
    - Set the Web Address to "Folder"
    - Enter the complete URL to the Document Library (e. g. , http://url of library).
    - Click the OK button.
     
  7. Return to the Search Settings page
     
  8. Under the Scopes section, click the "Start Updates Now" link.

When you have completed creating the scope and updating it, you should be able to see that it contains a number of documents. This is a good check that you have created the scope correctly and it contains the number of documents that you expect.

Make the Shared Scope Available in the Site Collection

An optional step is to make the new scope available to the site collection where the Search Center is located. Follow these steps to do that:

  1. From the home page of your portal, select Site Actions>>Site Settings>>Modify All Site Settings
  2. On the Site Settings page, under the Site Collection Administration page, click the "Search Scopes" link

On the View Scopes page, you should see the new scope listed under the Unused Scopes section. At this point, you could easily add the scope to the Search Dropdown that appears at the top of the page in MOSS by clicking on the "Search Dropdown" link appearing in the "Display Group: Search Dropdown" section. However, our goal is to create a tab for the search scope.

Create the Search Center Tab

New tabs for Search Center involve several different parts. First, you must create a search page. Then you must create a search results page. Finally, you must associate the scope with the new pages and create tabs to display them. Follow these steps to get it all working:

  1. From the Search Center page, select Site Actions>>Create Page
     
  2. On the Create Page

    - Enter Best Practices Documents Search in the Title field
    - SharePoint should automatically generate a valid page name
    - Select "Search Page" from the list of available Page Layouts
    - Click the Create button
     
  3. A new page should now be visible with a Search Box web part
    - Select Modify Shared Web Part from the web part's edit menu
    - Expand the Miscellaneous section
    - Enter BestPracticesDocumentsResults.aspx in the Target Search Results Page URL field (you will create this page next)
    - Uncheck the box labeled "Display Advanced Search Link"
    - Click the OK button
    - Click the Publish button at the top of the page
     
  4. From the new page, select Site Actions>>Create Page
     
  5. On the Create Page

    - Enter Best Practices Documents Search Results in the Title field
    - SharePoint should automatically generate a valid page name
    - Select "Search Results Page" from the list of available Page Layouts
    - Click the Create button
     
  6. A new page should now be visible with a several search web parts

    - Select Modify Shared Web Part from the Search web part's edit menu
    - Expand the Miscellaneous section
    - Enter BestPracticesDocumentsResults.aspx in the Target Search Results Page URL field
    - Uncheck the box labeled "Display Advanced Search Link"
    - Click the OK button
    - Select Modify Shared Web Part from the Search Core Results web part
    - Expand the Miscellaneous section
    - Enter Best Practices Documents in the Scope field
    - Click the OK button
    - Click the Publish button at the top of the page
     
  7. From the new page, select Site Actions>>View All Site Content
     
  8. On the All Site Content page, click the "Tabs in Search Pages" link
     
  9. On the Tabs in Search Pages list, click the New button
     
  10. On the New Item page

    - Enter Best Practices Documents in the Tab Name field
    - Enter BestPracticesDocumentsSearch.aspx in the Page field
    - Click the OK button
     
  11. From the list, select Site Actions>>View All Site Content
     
  12. On the All Site Content page, click the "Tabs in Search Results" link
     
  13. On the Tabs in Search Results list, click the New button
     
  14. On the New Item page

    - Enter Best Practices Documents in the Tab Name field
    - Enter BestPracticesDocumentsSearchResults.aspx in the Page field
    - Click the OK button

Return to the Search Center home page and you should now see a new tab visible for Best Practices Documents.

COMMENT USING

Trending up