Saturday, 24 October 2015

SharePoint 2013 Search – Display Error: The display template has an error…

SharePoint 2013 Search – Display Error: The display template has an error…

Another silly one… If you are testing search while directly on the server, you may see the following issue:
Display Error: The display template had an error. You can correct it by fixing the template or by changing the display template used in either the Web Part properties or Result Types.
Automation server can’t create object (CoreRender: ~sitecollection/_catalogs/masterpage/Display Templates/Search/Item_CommonItem_Body.js)
SNAGHTML6dcdf049[4]

A simple fix is to add the url of the site to the Local Intranet zone or Trusted Sites zone in Internet Explorer.
SNAGHTML6dd2b710

From Internet Options, select the Security tab, select Local Intranet zone (or trusted sites zone). Click Sites, and add the site under Advanced.


Tuesday, 20 October 2015

Search With FBA


  • Search With FBA


    ​​When you configure form based authentication sometime is is need that  you disable Integrated Windows Authentication. By doing so search does not work as per expectation and you may face error. If you check in crawl log you will saw following notification error message.
    Error:
    Access is denied. Verify that either the Default Content Access Account has access to this repository, or add a crawl rule to crawl this repository. If the repository being crawled is a SharePoint repository, verify that the account you are using has "Full Read" permissions on the SharePoint Web Application being crawled. ( HttpStatusCode Unauthorized The request failed with HTTP status 401: Unauthorized. )

    Reason:

    This error will occur, when search engine tries to crawl the content using the URL but as there is a change in user identity server is unable to access database and server will reject the request.

    Solution:
    For SharePoint Search you need Integrated Windows Authentication for crawling the content database. To resolve this issue we need to create extended website. Follow below steps to extend 
    1.  Go to Central Administration and select your Form Based Authentication website and extend your website with integrated windows authentication enabled. Note, when you extend website you have different site in IIS.
    2. Now modify your search service application's content source and in content source give your extended website URL instead of live site url(Form-based authenticated site).
    3. Once you do that, click on content source and start full crawl. After crawl completes you will not face above error and search result is coming.
    4. If you check in your site now you may observe that search result is coming with extended site URL not with live site URL. To display live site URL open your Search Service Application and in the crawling section click on Server Name Mappings.
    5. From Server Name Mappings click on New Mapping.
    6. "In Address in index" give your extended site URL and "In address in search results" give your live site URL and click on Ok.
    7. Now once again click on content source and start full crawl. Now result will come with your live site URL.
     

     Please comment.