SearchResult
Represents one item in the SearchResults.
Display all search results
<ul>
#foreach ($searchResult in $searchResults.items)
<li>$searchResult.description</li>
#end
</ul>
Additional context for $searchResult.object
If the search-result-object is of type 'page' you get access to the page-object and it's properties when calling $searchResults.object.
Methods
Name | Type | Description | ||||||
---|---|---|---|---|---|---|---|---|
$searchResult.absoluteLink | String | The absolute link to this object. | ||||||
$searchResult.description | String | A description of this search result (usually the page or blog post title). | ||||||
$searchResult.displayTitle | String | The display title of this search result (usually the page or blog post title). | ||||||
$searchResult.getDescription(maxLength) | String | A description of this search result (usually the page or blog post title).
| ||||||
$searchResult.getProperty(key) | String | The property of this search result for the given key. This will access the so-called content properties, which are different from the properties defined by the Page Properties macro.
| ||||||
$searchResult.link | String | The relative link to this object. | ||||||
$searchResult.linkAsText | String | The relative, decoded link to this search result. | ||||||
$searchResult.object | Linkable | The backing object of the search result. | ||||||
$searchResult.qualifiers | List<SearchResultQualifierPlaceholder> | A list of this search result's qualifiers. Qualifiers are only available when using the CQL search. Returns: the qualifiers | ||||||
$searchResult.type | ContentType | The type of the search result.
|