There are several reasons a category might not show up in search:
- Category type not included in search results: Check what type of category it is: only custom content and topic display categories are indexed for search. Default, blog style, and URL redirect categories aren't currently indexed for search.
Workaround
If you have another category type that you'd like to show up in search, create an article with the same name that is hidden from navigation and redirects to your category URL. This way, the article shows up in search but opening it takes readers to your category. - Category edited to exclude from search results: If it's a custom content category or a topic display category, check the category's Display Settings. If the Exclude from search results box is checked, that prevents the category from showing in search results. Uncheck it and save to get your category back in search.
- Search settings edited to exclude from search results: If it's a custom content category or a topic display category and that Exclude from search results box isn't checked, go to KB settings > Search and synonyms > General settings tab. In the Reader controls section, check if the Exclude category section lists this category or one of its parent categories. If it has, the category can't be shown in search results, and you'd need to remove this category from being excluded or put it in a different parent category to have it show up. Refer to Excluded category for more information.
- If you have a custom content category or topic display category that isn't showing in search and you've tried all of the above steps, contact us for more help figuring out what's going on!
Short answer: You generally don't have to!
You don't need to explicitly add keywords to your articles for your content to be searchable. We automatically add your article title, body, permalink, meta description, and PDF content to search. As long as you're entering content in those fields, that content is treated as keywords.
If you have a keyword or search term that doesn't appear in your article (or you want to boost the relevance of an article for a certain keyword), use search phrases. Search phrases are like keywords in that they are hidden from the reader but indexed for search. You can boost the weight given to search phrases under KB settings > Search and synonyms > Fine tuning tab. Refer to Fine tuning search and Search field weights for more information on using these settings.
If a reader searches for a hyphenated word as a single word (such as backup) and your documentation always uses the hyphenated word (back-up), they won't necessarily get the search results they need.
This happens because when we index your content, hyphenated words are split on the hyphen. This stores them as two separate tokens, so "back-up" becomes "back" and "up".
For example, we have an article called List of Sub-processors but searching for "subprocessor" didn't automatically return the article because the word "sub-processor" gets stored as "sub processor" in the search index. As far as our index is concerned, that word wasn't added!
To work around this issue, create the single non-hyphenated word as a synonym:
- Go to KB settings > Search and synonyms. The page opens to the General settings tab.
- Open the Synonyms tab.
- Create a synonym using these settings:
- Original word: Enter the hyphenated word used in your documentation, but replace the hyphen with a space.
- For example, if our documentation says
sub-processor
, we'd entersub processor
as the Original word. If we're usingback-up
, we'd enterback up
.
- For example, if our documentation says
- Enter a Synonym that is a single word with the hyphen removed.
- For example, we'd enter
subprocessor
orbackup
.
- For example, we'd enter
- Original word: Enter the hyphenated word used in your documentation, but replace the hyphen with a space.
- Save the synonym, then Run a required search reindex.
Once we reindex with the synonym, a search for "subprocessor" now finds the "sub-processor" article and a search for "backup" now finds a "back-up" article.
Go search "subprocessor" and "sub-processor" yourself if you'd like to see this in action!
New to synonyms?
Refer to Intro to synonyms to get a deeper understanding of what synonyms are and how you can use them.
You can exclude one category--and all of its contents--from search automatically using our Exclude category from search setting.
You can also always exclude individual articles from search using the Display settings box to Exclude from search results in the article editor.
When you create an article as Share content from an existing article, that article doesn't have its own content--it inherits the content from the original article. By default, these shared content articles aren't shown in search, to prevent duplicate titles or noisy results.
If you'd like to include these articles in search:
- Go to KB settings > Search and synonyms. The Search and synonyms page opens to the General settings tab.
- In the Reader controls section, under Shared content articles, uncheck the box to Prevent articles that inherit their content from another article from being searched.
- Be sure to Save your changes.
Google Custom Search Engine allows you to create a custom search engine for your knowledge base powered by Google. It's free, but you are required to show ads unless you are a non-profit or a school. If that's not a dealbreaker for you, you can also monetize your knowledge base using Adsense.
You can learn more on Google's Custom Search Help or create a custom search engine here.
Implementing Google CSE in KnowledgeOwl
To integrate Google CSE in to your KnowledgeOwl knowledge base, you'll need two things:
- A page to hold your CSE code
- A search form to send your readers to the search page
Creating a page to hold the search results
We recommend using a custom content category for your custom search. This will provide a nice blank canvas for the search input and results to be displayed. You can check the option to hide the category from navigation so it doesn't show up in your navigation.
You can drop your CSE JavaScript snippet directly into the body of the category. Using the Standard element type is the easiest to implement, though you may have to do a bit more work to override Google's default styles if you'd like a branded search form.
Now's a good time to pause (and save), and check out your new search page! Click View Category at the top of the screen to see your custom search page in action.
Adding search forms to your homepage or articles
Allowing your readers easy access to this search page is the next important piece of the puzzle. At its simplest, this could be set up with an ordinary hyperlink to the category page ("Click here for our search page").
You can go a step further by using an HTML form instead of a hyperlink. This will allow you to add a textbox, and pass the reader's search terms as a query string to your search page. Google CSE automatically picks up queries embedded in the URL, so seamlessly integrating this new search capability anywhere in your knowledge base becomes a snap!
Below is an example of how this search form might look.
<form action="/help/search-results/" method="get">
<input name="q" type="text">
<button type="submit">Search</button>
</form>
Three important things to note:
- The form action points to the URL of the search "category page".
- The form method is "get".
- The text input name is "q".
The text input name you can actually change to whatever you'd like, be sure to make the necessary adjustments to your Google CSE code, so it knows to look for the query string by that variable name.
By including a form like the one above on your homepage or in your top navigation, your readers will now have easy access to your Custom Search Engine!