Recent Articles List

For knowledge bases using individual reader accounts, our Recent Articles List displays a reader's most-recently-viewed articles, topic display categories, and custom content categories. These links can help readers return to content where they left off, or content they frequently reference. Your home page is an excellent place to add this article list, though you can also add it to the right column of your layout, if you're using the right column.

This list only works with individual reader accounts. Knowledge bases with default access set to public, shared passwords, or shared IP addresses will not properly populate this list.

How does it work?

To set up, you'll add the merge code for the list where you'd like the information to be displayed. Behind the scenes, KnowledgeOwl will track up to ten of the most recently viewed articles, topic display categories, and custom content categories for each reader, and display those back to the reader in the article list.

Sample Recent Articles List

Articles are displayed with a document icon; topic display and custom content categories are displayed with a folder.

The Recent Articles list will not show:

  • Default categories
  • Blog style categories
  • URL redirect categories
  • Articles set with URL redirects 

With topic display categories, if you have the option set to Override Article Links (so that opening an article always opens it within the topic display category), when a reader views an article in the category, both the topic display category and the article will appear in their recent articles list.

Setup

By default, the reader's five most recently viewed articles will be displayed. You can change this to display between 1-10:

  1. Go to Settings > Basic.
  2. Scroll to the Article List Settings section.
  3. Select the dropdown next to Recent Articles and select the number of articles you'd like the list to display (1-10):
    Select the number of articles to display in the Recent Articles dropdown
  4. Be sure to Save your changes.

We don't add this list to any section of your knowledge base by default.

If you'd like to add it, you'll add two merge codes into either the top-level Homepage or into the Settings > Style > Custom HTML of the relevant layouts:

  • [translation("article-lists:recent-articles")]: this merge code grabs the Recent articles list heading in Tools > Customize Text > Article Lists, making it so no one has to edit the code in the future to update the title.
  • [reader("recent-articles")]: this merge code generates the individual reader's recent articles list.

Different setups are discussed further below.

Add the Recent Articles List to your homepage (Settings > Style)

Most knowledge bases have their article lists set in Settings > Style. If your knowledge base uses this layout, you can follow these instructions to add the Recent Articles List there. (If your knowledge base doesn't show any article lists in Settings > Style > Custom HTML > Home Page, follow the next set of instructions!)

  1. Go to Settings > Style.
  2. Below the Preview pane, be sure Custom HTML is selected.
  3. Select Home Page from the Custom HTML dropdown.
  4. Near the bottom of the code editor, find the div with class="homepage-widgets row".
  5. Copy one of the other article lists and paste that code in again.
  6. Replace the title merge code with: [translation("article-lists:recent-articles")]
  7. Replace the list merge code with:[reader("recent-articles")]
  8. Your code should now look something like this:
    <div class="homepage-widgets row">
        <div class="col-md-4 col-sm-6"><h3></h3>[template("pop-articles")]</div>
        <div class="col-md-4 col-sm-6"><h3></h3>[template("new-articles")]</div>
        <div class="col-md-4 col-sm-6"><h3></h3>[template("up-articles")]</div>
        <div class="col-md-4 col-sm-6"><h3></h3>[reader("recent-articles")]</div>	
    </div>
  9. You can Preview your changes to be sure they look right.
  10. Be sure to Save your changes once you're done!

Add the Recent Articles List to your homepage (top-level Homepage)

There are two ways to do this, depending on how your knowledge base is set up. If you're using our older home page:

  1. In the top lefthand navigation, go to Homepage.
  2. Copy one of the other homepage lists and paste it in again.
  3. Replace the title with this merge code: [translation("article-lists:recent-articles")]
  4. Replace the merge code with:[reader("recent-articles")]
  5. Save.

Add the Recent Articles List to all articles

You can place the recent articles merge code and title in the HTML of all articles. To do so, it's best to create a div and add the title within a header and the article list merge code below that. We provide a code sample below you can copy and paste and adjust as you'd like:

  1. Go to Settings > Style
  2. Be sure the Custom HTML tab is selected.
  3. Select Article from the Custom HTML dropdown.
  4. Copy the code below:
    <div class="recent-articles text-center">
      <h3></h3>		
      [reader("recent-articles")]
    </div>
  5. Paste it in wherever you'd like. We recommend placing this in the hg-article-footer div, either above or below the Related Articles section:
    Sample Recent Articles section added above the Related Articles section
  6. Once you're done adding the merge code, text, and any Custom CSS to style it, be sure to Save.

Add the Recent Articles List to individual articles

If you only want to display the recent articles list in certain articles, we recommend creating a snippet that includes the recent articles merge code and whatever additional formatting you'd like, and then adding that to the individual articles where you'd like the list displayed.

This helps standardize the appearance of the list, regardless of where it's added.

To do so:

  1. Go to Library > Snippets.
  2. Select the + Create New Snippet button.
  3. Give your snippet a Snippet Name and Snippet Description.
  4. In the Snippet Content, create the layout you'd like for the list (usually a heading, etc.). Add the merge code for both the list and the list heading into it. Here's a sample:
    A sample Recent Articles snippet. The editor includes a centered heading level 2 that contains the merge code for the recent articles list header and a centered paragraph beneath it containing the recent-articles reader merge code.Sample Recent Articles snippet
  5. Once you're satisfied with your snippet, select Create.
  6. With the snippet created, you can add the snippet into any article using the Insert Snippet option in the editor.
    The Insert Snippet option

Add the Recent Articles List to the right column of your Knowledge Base

If you're using an older theme that shows the right column, you might decide to display the Recent Articles List in the right column of your knowledge base. To do so:

  1. Go to Settings > Style.
  2. Be sure the Custom HTML tab is selected.
  3. In the Custom HTML dropdown, select Right Column.
  4. Copy the code below and paste it in where you'd like. We recommend putting it before or after one of the existing article lists:
    <div class="panel panel-default right-col-panel recent-panel">	
      <div class="panel-heading">Recent Articles</div>
      
    </div>
  5. Be sure to Save your changes.