0

Is there any way to get the absolute results on a Low Search results page outside of the {exp:low_search:results} tag pair?

Something like:

{exp:low_search:absolute_results query="" collection="" limit=""}

So I can do this without the tag pair extra coding:

<a href="#venues">
    Show all {exp:low_search:absolute_results query="{segment_2}" collection="venues"} Venues found
</a>

Using the tag pair once or twice on a page is fine but it starts to get unwieldy after a while because I am grouping the collections on Bootstrap tabs and other UI foolery.

1

This is not possible at the moment.

When Low Search filters entries, it will pass on its search results (the the form of entry IDs) to the native channel:entries tag. This, in turn, will filter down the entries even further depending on things like status, future/expired entries and other native parameters.

EE currently does not offer an API for firing those filters and returning just a results number -- this is only available when calling the channel:entries tag with the absolute_results var.

| improve this answer | |
0

Depending on what else you are doing on the page, you could of course simply save the results of the tag-pair(s) when you first run them and then get those back later in the page. There are several ways to do this, including stash and CE Variables (both of which are free).

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.