You use display templates to control the ways in which search results appear and behave in search-related Web Parts. There are many pre-configured display templates, and you can create other display templates. You use a result type to specify a display template that the search system should use for a particular type of search result. This might be a type of search result that you want users to be able to distinguish easily from other types of search results, and for which you want to provide a particular appearance and behavior on the search results page. There are also many pre-configured result types, and you can create other result types. You can configure result types at the site collection level and at the site level.
Each result type specifies one or more conditions to compare search results against, such as the type or the result source of the search result, and an action to take if a search result meets those conditions. The action specifies the display template to use for the search result. For example, a pre-configured result type named Person specifies that if a search result is from the result source Local People Results, then use the People Item display template for that search result. The People Item display template shows information in the hover panel such as documents authored by the person and enables the user to go directly to those documents.
To create a result type, do one of the following on the Manage Result Types page:
-
Click New Result Type.
-
In the list of existing result types, click the name of a result type, such as Person, and then click Copy so that you can modify the copy to create a new result type.
For more information, see:
-
SharePoint Server 2016: Customize search result types in SharePoint 2016 (TechNet)
-
SharePoint Server 2013: Customize search result types in SharePoint 2013 (TechNet)
-
SharePoint: Manage result types (Office.com)
No comments:
Post a Comment