Product DocsMenu

Coveo Platform 7.0 >
Administrator Help > Coveo .NET Front-End 12.0 > Microsoft SharePoint Integration > Enabling Search Links for My Site User Profile Information in SharePoint 2010

Enabling Search Links for My Site User Profile Information in SharePoint 2010

In Microsoft SharePoint 2010 My Site pages, when the Search Center is configured correctly, you can click on user profile information to trigger a search to find people with the same information (past projects, skills, interests, etc.).

In SharePoint 2010, the implementation of how user profile information is automatically converted to search links is hard coded to use the Microsoft search engine and search box, not the search engine globally defined for the site, like when Coveo is used.

The workaround consists in integrating the Coveo search box in the My Site section. This is done by performing the following tasks:

  1. When not already done, activate the Microsoft Enterprise Search Center to make the user profile information links clickable (see Making information search links clickable).

  2. Replace the Microsoft search box by the Coveo search box in the My Site ASCX template file (see Integrating the Coveo search box in the My Site ASCX template).

    Note: When Site Collection Administrators are allowed to detach pages, My Site pages can be customized. When pages are ghosted, the customized pages do not use the My Site ASCX template from the file system. You therefore need to also replace the Microsoft search box by the Coveo search box in the ASCX files for the customized My Site page. For more information on ghosting, refer to the Ghosting & unghosting in SharePoint 2010 MSDN blog post.

The Coveo search box replacing the Microsoft search box
Example of clickable search links for user profile information

Making information search links clickable

When the My Site information from the user profile are not clickable search links, activating the Microsoft Enterprise Search Center makes them clickable. The following procedure describes how to create a dummy site collection based on the Enterprise Search Center template only to activate the search links, not to actually use the search center.

  1. Using an administrator account, start SharePoint 2010 Central Administration.

  2. Create a new dummy site collection using the Enterprise Search Center template:

    1. Select Central Administration > Application Management > Create site collections.

    2. In the Create Site Collection page:

      1. Under Title and Description, enter a dummy title.

      2. Under Web Site Address, enter a URL of your choice and make a copy of the URL.

        Example: http://MySP2010Site/sites/EnterpriseSearchCenter

      3. Under Template Selection, select the Enterprise tab, and then select Enterprise Search Center in the list.

      4. Under Primary Site Collection Administrator, enter the User name for the site collection administrator.

      5. Click OK.

  3. Validate that the My Site Settings contains the URL of this new site collection:

    1. Select Central Administration > Application Management > Manage Service Applications > User Profile Service Application > Setup My Sites.

    2. Under Preferred Search Center, in Preferred Search Center, paste the URL that you copied in the previous step, and then add /pages at the end of the URL.

      Example: http://MySP2010Site/sites/EnterpriseSearchCenter/pages.

    3. Click OK.

  4. Reload the My Site page of a user to verify that the clickable search links appear for user profile information.

Integrating the Coveo search box in the My Site ASCX template

On each SharePoint 2010 front-end server, perform the following procedure to replace the Microsoft search box by the Coveo search box in the top navigation of the ASCX template for the My Site pages. Editing the template applies the changes to the My Site page of all users.

  1. Using an administrator account, log in to the SharePoint 2010 front-end server.

  2. You need to download a ZIP file to correctly display the Coveo search box in the My Site pages:

    1. Download the CES70_SP2010MySiteRevA.zip file from the Coveo website.

    2. Extract the ZIP file to a folder of your choice.

    3. Copy the SearchBoxPeople.ascx file located in the \Skins\SharePoint2010 folder of the ZIP file to the following folder:

      [.Net_Front-End_Path]\Web\Coveo\Skins\SharePoint2010

  3. Using a text editor:

    1. Open the following ASCX file (default location):

      C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\CONTROLTEMPLATES\MySiteTopNavigation.ascx

    2. At the beginning of the file, add the following line after the last existing <%@ Register TagPrefix="... line:

      <%@ Register TagPrefix="cessp" Namespace="Coveo.CES.Web.Search.SharePoint.Controls" Assembly="Coveo.CES.Web.Search.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=44110d16825221f2" %>
    3. Towards the end of the file, replace the following code segment:

      <div class="ms-globalnavsearch">
        <div class="s4-search s4-rp">
        <SPSWC:PeopleSearchBoxEx
               ID="MySiteGlobalSearchBox"
               FrameType="none"
               HonorUseSiteDefaults="true"
               IsMysiteSearchBox = "true"
               DropDownMode="HideScopeDD"
               ShowSearchOptions="false"
               GoImageUrl="/_layouts/images/ppl_search_normal.png"
               GoImageUrlRTL="/_layouts/images/ppl_search_normal_rtl.png"
               GoImageActiveUrl="/_layouts/images/ppl_search_active.png"
               GoImageActiveUrlRTL="/_layouts/images/ppl_search_active_rtl.png"
               QueryPromptString="<%$Resources:sps,MySiteTopNav_PeopleSearch_Text%>"
               runat="server"/>
        </div>
      </div>

      with the following code segment:

      <div class="ms-globalnavsearch" style="padding-top: 9px;">
        <cessp:SharePointSearchBox Template="SearchBoxPeople.ascx" IsPeopleSearch="false" runat="server" />
      </div>  

      Note: Set IsPeopleSearch="true" to make the search page open in the People interface.

    4. Save the file.

  4. Reload the My Site page of a user to verify that the Coveo search box is now appearing in the top navigation section of the page.

  5. Repeat the procedure for each SharePoint 2010 front-end server.

People who viewed this topic also viewed