Issues displaying search results on the Content Editor Search tab


Description

When using the Search tab in the Content Editor to search for Sitecore items, the following issues might appear while displaying the search results.

Issue 1

When configuring the Multilist with Search fields to be displayed as part of the search results, raw values of such a field might be shown instead of the relevant item names:

search results when searching in the Content Editor

For more information about configuring item fields to be displayed in the search results, check the following article:
Configure search results

Solution

To address the issue, apply the following patch:

  1. Put the Sitecore.Support.404260.dll file in the \bin folder of the website.
  2. Put the Sitecore.Support.404260.config file in the \App_Config\Include folder of the website.

Issue 2

In certain situations, the HTML layout of the search results might be broken.

This happens because the size of each record in the search results is internally limited to 250 characters. This causes excessive characters to be skipped, resulting in HTML tags not being closed, styles not being properly applied, and so on.

Search results that display the following field types are potentially affected by the issue:

Solution

To address the issue, proceed as follows:

  1. Open the \sitecore\shell\Applications\Buckets\scripts\ItemBucket.js file.
  2. Find the line that contains the following statement:
    (this.Content.length > 250 ? (this.Content.substring(0, 250) + "...") : this.Content)
  3. Modify the statement according to your needs. You can either increase the limit of displayed characters:
    (this.Content.length > 2000 ? (this.Content.substring(0, 2000) + "...") : this.Content)
    or disable the limit completely:
    (this.Content)
  4. Save the file, clear your web browser's cache, and restart the browser.