Logga

Predefinied search - Advanced

In the Advanced view, you can set up sort order, and change the templates for how the search listing will look if you can manage scripting languages.

Advanced

Access control

Here you determine how the hits are to be to access controlled. The choices available are:

  • Early check (use permissions in query)
  • Late check (via filtering of search results)

This is a performance-related setting. It is performance-demanding (time/memory) to retrospectively check all hits of a search result. The default setting is early check.

However, the use of late check may be necessary if early check cannot be used. An example of such a potential case is whether there are IP address ranges set up on the website. These allow some non-authenticated users (via their IP-number) to have the right to read certain pages - even though they are not public. If early check is used, non-authenticated users will only receive public pages/files/images in their search results.

Sort order

The search results are listed/sorted by hit points (relevance) if no specific sort order is set. The hit points are calculated by the search engine and depend on how important the search query is in relation to the documents found. The calculation of the points depends on many factors and correlations, but the most crucial are:

  • how many times the search word is included in the text
  • how early in the text the search word is
  • how much of the text the search word is (the search word ranks higher in a short text than long text)
  • how the index field in which the search word appears is prioritised
  • how the hits are prioritised

If you want to deviate from the relevance sort order (i.e. "best" hits first), you can specify which field(s) this module should use as standard.

Use custom sort order for hits

Tick this box and click the Add link to add a sort order field. A new view appears:

Add sort order

Field name

A sortable (a field that is not analysed and does not have multiple values) field that is in the search index. E.g. "name", "name.sortable", "title", "title.sortable" och "lastpublished".

To sort on metadata, the field name begins with "metadata.sortable.". If your metadata is named "keywords", the field name is named "metadata.sortable.keywords".

Order

Search results can be displayed in ascending or descending order. By default, search results are sorted ascending.

An example of custom sorting. To sort by last publish date:
Field name: last published
Order: Descending

Templates

Here you can change the appearance of the search listing module if you have scripting skills.

Use custom template for the structure of template parts

To change how the search results are structured, change the template. That is, if you want to change the order of how things are presented. For example, to display "Did you mean" under the paging.

Use custom template for hits

Change this template if you want to affects the appearance of how the hits of the search results are presented. For example, to add more information from a metadata field.

Use custom template for error messages

Change this template if you want to affect the error message that is displayed.

Help with scripts is not included in the support agreement.

Further information for developers (English only)

The code in the custom templates for this module uses SiteVision’s public API
Available elements in the custom template

The page published: 2019-01-08

Find us!

SiteVision AB (Headquarter)
Vasagatan 10
702 10 Orebro
Sweden


Info: +46 19-17 30 30
Support: +46 19-17 30 39