Customizing Search Series – Creating the Custom Results Page

This entry is part 5 of 7 in the series Customizing Search

This is the fifth article within the Customizing Search Series. This article continues to build out the customization of search using a new content source based on the BDC. When we previously setup a custom scope, we left the target search page as the default. Now, we will create a new search results page for the client scope which will then be used to customize the actual rendering of the search results.

Custom Search Page Creation

The out-of-the-box Search Center actually contains both a Search Page and a Search Results page for All Sites and People. Therefore, to be consistent, we should also create a Search Page and Search Results Page for our new Clients scope.

First we will create the Search Page. Go to the Search Center site and select Create Page from the Site Actions menu:

On the Create Page screen enter Clients for the Title of the page and the URL name. Select the Search Page layout and then click on Create:

The new page will appear in Design mode. Edit the Search Box web part and enter “ClientResults.aspx” in the Target search results page URL setting (under Miscellaneous):

Click OK and Publish the page.

Creating the Search Results Page

The creation of the search results page is the same process. Go to the Search Center site and select Create Page from the Site Actions menu:

On the Create Page screen enter Client Results as the Title of the page and ClientResults for URL name. Select the Search Results Page layout and then click on Create:

The new page will appear in Design mode. Edit the Search Box web part and enter “ClientResults.aspx” in the Target search results page URL setting (under Miscellaneous):

Click OK and Publish the page.

Creating New Tabs

Go back to the main Search Center again and Edit the Page. Click on Add Tab near the top:

This will bring up a screen to add a new tab (for Search Pages). Enter Clients for the tab name and Clients.aspx as the page (remember this is for the search pages, the results are next):

Click Ok and publish the page.

Perform a search under the All Sites scope such that the results page appears. Edit this page and click on the Add New Tab towards the left of the screen:

This will bring up a screen to add a new tab again but this time it will be for the Search Results Pages. Enter Clients for the tab name and ClientResults.aspx as the page:

So now the Search Center should be loaded up with a Client Search Page, Client Search Results Page, and the appropriate tabs.

Updating the Client Scope

Now that we have the client results page created, we need to go back and update the scope such that any search within the client scope uses the proper results page. Therefore, back in Central Administration under the Search Settings, click on the View Scopes within the Scopes section:

On the next screen, select the Clients scope to bring up the scope properties and then click on the Change Scope Settings link:

This will bring up the Edit Scope screen. Simply change the Target Results Page setting to the “Specify a different page for searching this scope” and enter “ClientResults.aspx” within the Target results page box:

Click OK. The scope will need to be updated but that happens automatically.

What’s Next?

We are coming down the home-stretch. Everything is now set-up for the customization of the search results. The final article will go into details in how we can use the managed properties and the results XSL to generate customized search results within our clients scope.

Series NavigationCustomizing Search Series – New Content and Scope from a BDC ApplicationCustomizing Search Series – Creating New Managed Properties
Twitter Digg Delicious Stumbleupon Technorati Facebook Email

No comments yet... Be the first to leave a reply!

Leave a Reply

Before you post, please prove you are sentient.

What is 8 * 9?