THIS IS ARCHIVED DOCUMENTATION

Adding Custom Parameters with the Additional Parameters Field Using the Coveo for Sitecore Legacy Search UI Framework

Coveo for Sitecore 4.1 (November 2018)

For each Coveo component, there’s a field named Additional Parameters located in the Parameters section. This field allows you to add custom parameters to the Coveo component. Therefore, you’re able to use those parameters in your sublayout files (ascx and ascx.cs).You can create a new parameter named ResultCssClass in order to add a custom CSS class to the results list.

Steps

  1. Open your Coveo Search Component properties.

  2. Scroll to the Parameters section (typically located near the end of the screen).

  3. Add the following values in the left and right columns:
    1. Left column: ResultCssClass
    2. Right column: disable-icon

  4. Choose OK and save your changes.
  5. Open your copy of the Coveo Search rendering or sublayout in a text editor (the default files are located under Website/Views/Coveo or Website/layouts/Coveo).

    Every Coveo component exposes the Parameters property, which allows you to retrieve the parameters that were set either directly on the component or in the Additional Parameters field.

  6. Locate the <div class="CoveoResultList" ...> line and add the ResultCssClass property to the class parameter:

     <div class="CoveoResultList <%= Parameters["ResultCssClass"] %>" data-wait-animation="fade"
                                                        data-enable-infinite-scroll="<%= EnableInfiniteScroll %>"
                                                        data-infinite-scroll-page-size="<%= InfiniteScrollPageSize %>">
    
  7. Open CoveoComponent.css (typically located under Website/Coveo/css/CoveoComponent.css).
  8. Add the following CSS block to hide the result icons:

     .CoveoResultList.disable-icon .coveo-icon {
       display: none;
     }
    
  9. Validate that the result icons are no longer displayed.