v3.1.9

Widgets

Since version 2.0.0 the whole frontend of the extension is based on Widgets.
The extension provides a bunch of Widgets of different types.
Each widget has the following configurations:

  • Template - the template for rendering the widget. Different widget types have different sets of templates.
  • Frontend Title - The text that can be displayed in the frontend as the title of the widget.

Most widget types are designed for configuring Blog pages.
The widget of the type Posts can be used on any page of the store.

Below is the information about different widget types provided by the extension:

  • Author - the widget to display the author's bio. This widget has 2 templates available - Full and Short. Common places where this widget can be used are the Author page and the Post View page.
  • Category List - the widget with category links (navigation) of the blog. This widget has only one template.
  • Newsletter - the widget with standard email subscribe form. This widget has only one template.
  • Search Box - the widget with the search bar to search through the blog. This widget has only one template.
  • Tag Cloud - the widget to display tags configured in the blog. This widget has only one template.
  • RSS - the widget with the link to the RSS feed of the blog. This widget has only one template.
  • Post List - the widget to display the list of posts from the blog. The content of this widget depends on the page it was placed on. The Post List uses page context to display posts. If this blog is added to the category page it will display posts for that category. If this widget is placed on the search result page it will display posts that will match the search query.
  • Post View - the widget to display the content of the post. It should be placed on the Post View page. On any other page type, this widget won't be displayed.
  • Post Comments - the widget does display comments for each post. It should be placed on the Post View page. On any other page type, this widget won't be displayed.
  • Related Products - The widget to display products related to the current post (added in the configurations of the post). This widget won't work outside the Post View page.
  • Posts - This is the most complex widget provided by the extension. It can be placed on any page of the website. This widget has a few preinstalled templates. More information about them can be found in the Posts Widget Templates section. This widget, except the common settings Template and Frontend Title, has the following additional configurations:
    • Limit - the limit of the posts displayed in the widget. Some templates might not be affected by this setting
    • Filter - configure how the extension will choose posts to display. This setting can be affected by the page context if the Use Page Context as Filter is enabled. This setting has the following options:
      • All posts - display all posts.
      • By tags - display posts by selected tags or by tag from page context (Tag page)
      • By categories - display posts from selected categories or by the category from page context (Category page)
      • By author - display posts filtered by selected authors or by author from the page context (Author page, Post View page)
      • Only pinned posts - widget to display pinned posts.
      • Only related posts - widget to display related posts.
    • Sorting Order - select how posts should be ordered in the widget. This setting has the following options:
      • By Creation Date
      • By Updating Date
      • By Name
      • By popularity
      • Use Page Context as Filter - defines should the widget considers page context or not. For filters All posts, Only pinned posts, and Only related posts this option defines should posts in this widget be filtered depending on the page the widget is placed on or not

        Example

        The widget is set to display only pinned posts and placed on the category page. If the Use Page Context as Filter is enabled the widget will display pinned posts only from the current category. Otherwise, all pinned posts from all categories will be displayed in this widget.
        For filters By tags, By categories, and By author this setting defines whenever the extension should use filter values from the widget configurations or from the page context

        Example

        The widget is set to filter posts by author and placed on the Author page. If the Use Page Context as Filter is enabled the widget will display posts by the current author. Otherwise, the widget will display posts by authors selected in the widget configurations.

Posts Widget Templates

The Posts widget is the widget that can be placed on any page of the store. This widget comes with a bunch of pre-installed templates with different designs:

  • Type 1 - single post widget (not affected by posts' limit configurations) widget_type_1.png
  • Type 2 - widget with one detailed post and a bunch of small posts listed in one column widget_type_2.png
  • Type 3 - widget with 2 detailed posts and a bunch of small posts listed as a grid (2 posts in a row) widget_type_3.png
  • Type 4 - widget designed to be placed in sidebar (vertical widget) widget_type_4.png
  • Type 5 - widget displaying posts as cards (2 posts in a row) widget_type_5.png
  • Type 6 - widget with the list of posts with detailed information widget_type_6.png
  • Type 7 - widget with small posts (2 posts in a row) widget_type_7.png

Widgets' Customizations

Each widget provides one or a few different templates. Widget templates can be overridden in the theme as any other template.

Note

Templates organized in folders which are named correspondingly to the widget type - templates/widget/[widget_type]
Each widget has access to templates only for its type.

The extension also supports custom templates for widgets.
Custom templates should be created in the same folder as if you overriding the original template but the name of the template file should duffer from already defined templates.
In the case of a store with different themes for different store views, custom templates should be added to each active theme. If some theme does not have a template selected in the widget's configurations the extension will fall back to one of the default templates provided by the extension.

Since version 2.0.0 Related posts for products are no longer added automatically. To display related posts on Product View pages an additional widget of the type Posts should be created. The common configurations of such widgets are shown in the following images related_1.png related_2.png

Note

For the store with multiple store views and themes the widget for related posts should be created for each active theme