Landing Pages
To create and administer landing pages, please refer to the official documentation https://hawksearch.atlassian.net/wiki/spaces/HSKB/pages/327857/Landing+Pages#LandingPages-CreatingaContentLandingPage
We have 2 ways to retrieve landing pages (just like we have 2 ways to make a search request):
Â
Using only Optimizely.Hawksearch.Client
Set the CustomUrl property directly in the SearchRequest object and do not set the Keyword property
Â
Using both
Optimizely.Hawksearch.Client and Optimizely.Hawksearch.Connector
Create and populate a SearchQuery object
Set the CustomUrl property of the SearchQuery object and do not set the Keyword property
If CustomUrl property is provided, the search request builder will always ignore the Keyword property. Thus, do not use CustomUrl for normal searching (searching that requires no landing pages as results)
Build a SearchRequest object by passing the created SearchQuery object to a SearchRequestBuilder and its Fluent API
Â
Example:
var query = new SearchQuery
{
CustomUrl = "/en/my-landing-page/" //Valid values are configured in Workbench > Merchandising > Landing Pages
};
Â