Two Instances of the Same Search Page Component Have Been Added on a Page but Only One is Initialized
Two Instances of the Same Search Page Component Have Been Added on a Page but Only One is Initialized
Coveo for Sitecore 4.1 (September 2017)
Symptoms
When adding two instances of the same Coveo Hive component on a page, only one is initialized. Here are the four components that display this behavior:
- Coveo Global Searchbox
- Coveo Date Facet Range
- Coveo Google API Position Provider
- Coveo Omnibox Result List
Cause
The four component templates are shipped with a fixed GUID in their __Standard Values
. Hence, all instances created from a given template inherit the same DOM Unique Id
.
Resolution
For Existing Component Instances
In the Sitecore Content Editor, you need to change the DOM Unique Id
field value on your components to avoid duplicate IDs.
If you have many Global Searchboxes on a page, you must change the DOM Unique Id
field value.
For Future Component Instances
You can force unique IDs to be generated automatically on all new instances of a component by setting the __Standard Values
Dom Unique Id
value to $GenerateNewUniqueId
in the Templates section of the Content Editor.