External Content

Warning
Legacy feature

This article pertains to the Coveo Hive framework which is now in maintenance mode.

Choose one of Coveo’s more modern, lightweight, and responsive libraries for any future search interface development. See the search interface Implementation guide for more details.

Coveo for Sitecore Specific Rendering This rendering adds external sources from your Coveo organization to the query by altering the constant query expression (cq) of search API calls (see About the query expression).

It registers a handler in the onBuildingSitecoreExternalContent event triggered by the CoveoForSitecoreExpressions component.

Usage notes

  • The External Content rendering is added automatically with the Coveo Search Interface and Coveo Tab renderings.

  • When external content sources are specified in a Coveo Search Interface data source, items from the specified sources are returned in search results, regardless of the selected search interface tab. When specified in a Coveo Tab data source, items from the specified sources are returned in search results when that tab is selected.

  • When the Sitecore Instance Filter Filter results based on the current Sitecore context database option is disabled, items from all your Coveo organization sources are included in search results, unless you explicitly specify target sources in the External Content rendering.

Insertion location

Coveo Hive

The External Content rendering is an Allowed Control in the following placeholder(s): UI Header, Recommendations Components, Searchbox Components

Example insertion sequence for the External Content rendering.

Coveo Hive SXA

The Coveo for Sitecore SXA External Content rendering is meant to be inserted in specific placeholders (that is, UI Header, Recommendations Components, Searchbox Components).

Example insertion sequence for the External Content rendering.

Data source options

Option name Description

Names of external content sources

The names of the Coveo organization external sources to search through on top of the Coveo source associated with the current Sitecore context database. Source names may be found in the Sources (platform-ca | platform-eu | platform-au) page. For multiple external sources, use a comma between your source names or list the sources on separate lines.

Sample Generated HTML and Corresponding Query Expressions

In the example below, two external sources were added in the Names of external content sources field of a Coveo Tab rendering data source.

Generated HTML:

<span class="CoveoForSitecoreExternalContent" data-sc-scope-to-tab="coveod9c70725"
data-sc-sources="techzample site,coveo docs">
</span>

Search API call cq:

External content cq | Coveo for Sitecore 5