How to Sort Results by Relevance When Searching in a Document - Fluid Topics - Latest

Version
Latest
Category
How To
Audience
public

How to sort by relevance when searching in a document

Business need

When searching in a document, matching topics appear in the same order as in the document's Table of Contents. It is sometimes useful to sort results by relevance instead.

Overview of the solution

The solution consists in modifying the RewriteArg search query parameter in the Back Office.

Procedure

SaaS users should create a Fluid Topics help desk ticket to request assistance. On-premise users should follow these steps:

  1. Access the Back Office.

  2. Open the Setup menu and select the Configuration option.

  3. In the Front Configuration section, select Front. The Front configuration interface appears with the Search tab opened by default.

  4. Enable the Show All toggle.

  5. In the Filter search box, start typing rewriteArg to display the rewriteArg option.

  6. Select Edit, then select Add.

  7. Define a key and a value as follows:

    • Key = afs:sort@FluidTopics=ft:tocPosition,ASC

    • Value = afs:sort@FluidTopics=relevance,DESC

  8. Select Save, then select I'm done with modifying.

  9. Select Publish to apply the new sort order.