Gravatar for alexander.kravchuk@apiqu.com

Question by Alexander Kay, Feb 22, 2019 6:01 PM

How to change results count on client side?

Hi everybody,

We are suing Coveo for Sitecore version: 4.1.729.23(Cloud) and Sitecore version: 9.0.1.171219.

How can I modify the count of the actual results coming from the query on client-side?

Thanks!

2 Replies
Gravatar for flguillemette@coveo.com

Answer by François Lachance-Guillemette, Feb 22, 2019 6:29 PM

You cannot directly alter the number of results, in the Query Summary component, as shown in the image above. This component takes the length of the `results` array and render it (see here).

The best thing you could do is extend or reimplement this QuerySummary component so that the number of results is adjusted to your liking.

Gravatar for alexander.kravchuk@apiqu.com

Comment by Alexander Kay, Feb 22, 2019 6:31 PM

Oh man, okay I'll try it :) Thanks a lot!

Gravatar for flguillemette@coveo.com

Answer by François Lachance-Guillemette, Feb 22, 2019 6:07 PM

In Coveo for Sitecore Hive, the `Search Interface` component's data source has the `Results per page` attribute that you can use to change the number of results.

If you want to give control of this value to your end-users, you can add the `Results Per Page` component to your Search Page, which allows you to front a results per page picker, like on the Example Search Page.

Note that if this component is included, the `Results per page` attribute of the search interface will not be used.

Gravatar for alexander.kravchuk@apiqu.com

Comment by Alexander Kay, Feb 22, 2019 6:11 PM

I'm looking for a way to change this number:

Ask a question