Hide Facet yet still allow for querying
I have a search results page with a number of facets on it (Coveo Facet View MVC Controls). I also have an Coveo Search View control, and am using the omnibox. Initial queries are submitted from a query string (form post) to a page called 'search' as so:
This works fine, as long as there is a facet control on the page for the @searchscope field, and none of the query string syntax shows up in the omnibox. When I remove the facet view for the @searchscope field, all results are returned, as there is no such facet any longer. If I revise the query string to look like:
This yields the correct results, but also places the "@searchscope="Products"" in the omnibox.
Is there any way to leave the facet on the page, but simply have it not displayed?
A better way to achieve your end result would be to:
- Remove your @searchscope facet.
- Use the
aqquery parameter instead of the
qparameter like this:
q parameter is for the "basic query expression". That's the one displayed in the search box of the search interface. The
aq parameter stands for "advanced query expression". This is the expression used by the search interface to filter the results. There is also a
cq parameter that is for "constant query expressions". Only query expressions that are fixed and won't change in time should be put in the
cq parameter as those are cached by the search index engine and those caches are refreshed every time it applies an indexing transaction.
I hope this helps you to achieve a clean search page implementation.