Use the Widget's Admin Settings to control the functionality of the widget behind the scenes, including if/how it suggests content and if/how it's authenticated. Go to KB Settings > Widget to access these settings.
Settings changes may require refresh due to browser caching
If you make changes to these settings, it may take up to an hour to see them in your browser due to caching. You can bypass the caching by doing a hard refresh.
Here's what each of the settings options does:
Recommended tab
Only for Contextual Help
This setting only applies if you're using the widget to automatically recommend content, as outlined in Use Widget 2.0 for Contextual Help: Recommend on Pages.
If you check the box to Display article when there is only one recommended, when the widget opens and there's only a single recommended article or category, the widget will automatically open that article or category.
If you leave the box unchecked, the Recommended tab displays the list containing the single article or category.
This setting doesn't impact widget behavior when there are multiple recommended articles or categories for a given page.
Be sure to Save any changes you make.
Regex Replace URLs
Only for Contextual Help
This setting only applies if you're using the widget to automatically recommend content, as outlined in Use Widget 2.0 for Contextual Help: Recommend on Pages.
In order for Contextual Help recommendations to work, the widget has to parse the URLs it finds to determine which content to show. Since URLs often contain ID values that might vary from user-to-user but the same overall path, Widget 2.0 includes a built-in regex that uses an {id}
variable. {id}
only works with numeric and 24-digit hexadecimal IDs.
If your website or application URLs have IDs that don't match those patterns:
- Define the regex you need the widget to use in Regex Replace URLs.
- regex101 is a handy site that allows you to try out Regex rules against example words and phrases. When testing regex for use in KnowledgeOwl, select PCRE2 (PHP >= 7.3) under FLAVOR.
- Be sure to Save any changes you make.
- Advise your authors to use the
{custom}
variable in your Recommend on Pages URLs, instead of{id}
.
Suggested content
Only for Contextual Help
This setting only applies if you're using the widget to automatically recommend content, as outlined in Use Widget 2.0 for Contextual Help: Recommend on Pages.
Use the Suggested content settings to control which portion of the URL the widget uses to identify recommended content and whether the widget should "learn" recommended resources based on what end-users on this page ultimately open in the widget.
First, select one of these options to set which portion of the URL the widget should use to identify recommended content:
- Suggest content based off of the page path (default): Use this setting if the website where you're embedding the widget uses the URL or page path to differentiate pages.
- For example, we use this setting for the widget in this Support knowledge base, since our page URLs are formatted without query strings and with no special characters.
- Use the page query strings to suggest content: Use this setting if you want to recommend based on query strings, which appear in the URL as
?variable=
, such as?s=
or?client=
.- If your website's URLs don't have query strings--or the query strings aren't meaningful for recommendation distinctions--don't use this setting.
- Disable automatic page suggestions: This option effectively turns off automatic page suggestions. If you select this option, the widget will only provide suggestions when the
_ko19.updateRecommended
method is being used. Use this setting if:- Youu plan to consistently override the page path or query string with our Single Page Application methods.
or - You don't want the widget to suggest content at all.
- Youu plan to consistently override the page path or query string with our Single Page Application methods.
Next, decide whether you want the widget to "learn" additional articles to recommend.
As people open the widget, we track which articles or categories people end up viewing from a given page. We save this information as the Learned Bias in Widget reporting. Once the Learned Bias of a resource gets high enough, the widget includes that article or category in the Recommended tab list automatically. This is the behavior your widget has if you leave the Exclude articles that have a zero starting weight box unchecked.
If you want tight control over the content that you're recommending, you'll want to disable the learning behavior. To prevent the widget from displaying these "learned" recommended pages, check the box to Exclude articles that have a zero starting weight. When this box is checked, the widget only recommends articles and categories you've explicitly assigned in the Recommend On Pages (it basically ignores anything that only has a learned bias).
Be sure to Save any changes you make.
OAuth Authentication
If you want or need to authenticate your widget using OAuth2, use this section to generate the OAuth client secret, enable OAuth authentication, or regenerate the client secret.
Refer to Widget 2.0 OAuth2 authentication for full instructions. Refer to Widget authentication--when and how to use it to figure out if you need authentication.
JWT Authentication
If you want or need to authenticate your widget using JWT, use this section to grab your JWT client secret, enable JWT authentication, or regenerate the client secret.
Refer to Widget 2.0 JWT authentication for full instructions. Refer to Widget authentication--when and how to use it to figure out if you need authentication.