Configure a Search Engine
The theme include the following Search Engine connectors:
- GhostHunter: included into the theme
- ElasticSearch: you have to configure the ElasticSearch server on your side. Here, a post that explain you how to use Elasticsearch as search engine for your Ghost blog
Note: if no search engine is configured, the search bar does not appear
GhostHunter
To configure GhostHunter as your Search Engine, you must follow this steps:
- Create a Custom integration named GhostHunter
- Copy the Content API Key
- From the Ghost Code injection, insert the following code into the Site Header
<script type="text/javascript"> var ghosthunter_key = '<YOUR_CONTENT_API_KEY>'; </script>
Elasticsearch
To configure Elasticsearch as your Search Engine, you must follow this steps:
- From the Ghost Code injection, insert the following code into the Site Header
<script type="text/javascript"> var elasticsearch_username = '<ELASTICSEARCH_USERNAME>'; var elasticsearch_password = '<ELASTICSEARCH_PASSWORD>'; var elasticsearch_auth = btoa(elasticsearch_username + ":" + elasticsearch_password); </script>
- If you Elasticsearch endpoint URL is different than the suggested one (
/api/search
), then precise the URL in addition to the other information:var elasticsearch_endpoint = 'https://my-elasticsearch.com';