Resolved: Remove Contextual Search Scope from Search Dropdown in SharePoint

By Default SharePoint search made up of two controls. First is a search drop down box that contains scopes.Second control is a serach box in which we type the keywords for search.

Scopes can be classified in two 2 categories.
1. Custom scope
2. Contextual scope

By default there are two custom scopes present in SharePoint:
1. All Sites
2. Peoples

In addition of these two scopes we can create our custom scopes according to our needs.

Well Contextual scope can be like this
1. This Site
2. This List

Depend upon the navigation the contextual scope changes.

* if we even remove the custom scopes it will always display atleast the contextual scope.

Well my article is here about how to get rid of contextual scope located in search dropdown box without any programming. In my scnerio i want a custom scope that search in a particular section of a site collection. We want this like we can search this site from any point of navigation. But after creating the custom scope and removing the default custom scope my search drop down was showing my custom scope with contextual scope i.e. This Site, that i din’t want to dispaly so that user could be restricted to only custom scope search. Well here what i did that.

1. Browse “C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\TEMPLATE\FEATURES\OSearchEnhancedFeature” folder inside your SharePoint server.
2. Open SearchArea.xml file in notepad. (Please make a copy of SearchArea.xml before doing any modification.)
3. Add this property “<Property Name=”DropDownMode”>ShowDD_NoContextual</Property>” after this “<Property Name=”UseSiteDefaults”>true</Property>” property.
4. Save and close the file.
5. Do a IISRESET.
6. Browse your site and voilla now in search dropdown you have only your custom scope. Contextual scope This Site is gone…

Happy SharePointing 🙂