Getting Started

Welcome to the documentation of Blog MX for Magento 2 extension.

Whether you are a new or an advanced user, you can find some useful information here.

First of all we recommend you check the following link:

  • How to install extension

How to install the extension

Prepare for installation

  1. Back up your store's database and web directory.

  2. Log in to the SSH console of your server and navigate to the root directory of the Magento 2 store.

  3. Copy the installation instructions from the page My Downloadable Products to the SSH console and press ENTER.

Install the extension via composer

  1. Run command to enable the extension

php -f bin/magento module:enable Mirasvit_Core Mirasvit_BlogMx

  1. Run command to install the extension

php -f bin/magento setup:upgrade

  1. Run command to clean the Magento cache

php -f bin/magento cache:clean

  1. Deploy static view files

    rm -rf pub/static/*; rm -rf var/view_preprocessed/*;
    php -f bin/magento setup:static-content:deploy

Install the extension for Hyva

  1. Run the command to obtain the Blog MX Hyva component
composer require mirasvit/module-blog-mx-hyva:*
  1. Enable installed Hyva component:
bin/magento module:enable Hyva_MirasvitBlogMx
  1. Update Magento database schema and data with the command:
bin/magento setup:upgrade
  1. Compile the code to generate the contents of Magento var/di folder:
bin/magento setup:di:compile
  1. Run the command below to clean the cache:
bin/magento cache:flush

Blog MX settings

The settings of Blog Mx are located at Content ▸ Blog MX ▸ Settings and are grouped into the following sections:

  • Appearence - basic configuration of the blog appearence in the frontend.
  • Display - additional configurations related to the blog appearence in the frontend.
  • Search Engine Optimization - SEO settings of the module
  • Comments - settings for comments in posts.
  • Sharing - configurations for sharing blog posts via social networks, email, etc.
  • Layout Settings - configurations related to the way pages of the blog will be displayed on the frontend.

Appearence

  • Top Menu Title - set the title of the blog for the main menu.
  • Blog Name - set the name of the blog that will be displayed on the main page of the blog and in the footer.
  • Date Format - set the way the date will be displayed in the blog pages.

    Example

    • F j, Y - March 10, 2001
    • Y-m-d - 2001-03-10
    • D, M j, Y - Sat, Mar 10, 2001

    Read more about accepted date format characters.

Display

  • Visible Navigation Menu - if enabled, the link to the blog will be added to the main menu of the website.
  • Enable excerpts on list page - When enabled, excerpts will be inserted as follows; if there is a tag in the post's content, the excerpt will go until that tag, next if the post has an excerpt that gets used, lastly, the first n characters of the post (as set below) will be displayed.
  • Default Excerpt Character size - set the limit for the number of symbols of the post content to be displayed on the posts list pages.

Search Engine Optimization

  • Base URL - the URL key for the blog (will be visible in the URLs for all blog pages).
  • Base Meta Title - the part of the page meta title that will be added to all blog pages.
  • Base Meta Description - the part of the meta description that will be added to all blog pages.
  • URL Suffix for Posts - the suffix of the URLs for all blog post pages.
  • URL Suffix for Categories - the suffix of the URLs for all blog category pages.

Comments

  • Provider - choose the provider for comments or disable them. Currently our extension only supports Facebook comments.

Sharing

  • Enable AddToAny Sharing Buttons - enable/disable AddToAny buttons.
  • AddToAny Sharing Buttons Code - add the code for AddToAny buttons. You can customize buttons and get the code here

Layout Settings

  • Sort posts by - choose the sorting for posts in all post list pages.
  • Posts per Page - set options for post per page appearence (options for pager toolbar). Comma sepparated values. The default value is 10,20,50.
  • Layout Editor - will redirect you to the Layout Editor to configure layouts of blog pages

Posts

Create a new blog post

Go to Content ▸ Blog MX ▸ All Posts. There you'll see all blog posts

post_grid.png

To create a new blog post, click on the Add New Post button and you'll be redirected to the post creation form.

post_form.png

Blog post score checker

Blog post score checker tool analyses the content of the post.

Click "Check content" of the blog post you're looking to analyze to identify possible content issues.

image

The score checker tool offers full-text analysis for SEO compliance.

image

Note

Please note that the score checker analysis is based on the fields of the blog posts in the admin.

Categories

Go to Content ▸ Blog MX ▸ Categories. There, you'll see the blog categories organized hierarchically

category_grid.png

To create a new category, click on the Add new button and you'll be redirected to the category creation form.
The form is split into 2 tabs:

  • General Information - main settings of the blog category.
  • Search Engine Optimization - SEO configurations.

category_form.png

Authors

Go to Content ▸ Blog MX ▸ Authors. There, you'll see all authors of the blog posts

author_grid.png

To create a new author, click on the Add New Author button and you'll be redirected to the author creation form.

author_form.png

Tags

Go to Content ▸ Blog MX ▸ Tags. There, you'll see all tags of the blog

tag_grid.png

To create a new blog tag, click on the Add New Tag button and you'll be redirected to the tag creation form.

tag_form.png

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

Layout Editor

The extension provides the ability to configure the layout for every page type of the extension separately.
Go to the Content -> Blog MX by Mirasvit -> Layout Editor or click the Layout Editor button in the Layout Settings section of the extension's configurations to open the Layout Editor.
The extension has preconfigured layouts for each page type. You can use preconfigured layouts or adjust them according to your needs.

editor.png

The Layout Editor interface has 2 sections.

The first section has 2 configuration fields of general settings:

  • Page Type - select the page type for which the layout will be configured. Layout settings should be saved before changing the page type. Otherwise, all unsaved configurations will be lost after changing the page type.
  • Layout - select the layout mode for the current page type. Available layout modes are 1 column, 2 columns with left bar, 2 columns with right bar, and 3 columns.

The second section is the Layout Editor itself. It contains 3 containers where different blocks (widgets) can be placed.
The position of those containers depends on the layout selected in the first section.

To add a new block (widget) click the + button at the bottom of the container in which the block should be inserted. After clicking this button a new block will be inserted at the bottom of the corresponding container.

To configure the newly added or existing block click on the gear icon (edit button) in the top right corner of the block. After clicking on this button the modal will be open with configurations of the block.
For a newly created block, the modal will contain only one configuration field - Widget Type. After selecting the type of the widget the configurations related to this widget type will be displayed. More information about configurations for different blocks can be found in the Widgets section of this manual.

modal.png

To change the position of the block click and hold on the arrows icon, move the block to the place where it should be placed, and drop the widget there.

editor_dnd.png

To delete the block click on the thrash bin icon (delete button) in the top right corner of the block.

After the layout for the page is configured press the Save button to save the layout configurations for the current page type.
No changes will be applied to the layout configurations of the page until the configurations are saved.
Clean the cache of your Magento store after the layout for blog pages is configured and saved.

Handle theme changes

When the layout for any blog page is saved the extension generates widgets for each block for all active themes in the store.
If the theme for any store view is changed to previously inactive or a new theme the command bin/magento mirasvit:blog:update-layout should be executed. The execution of this command will update widgets for all active themes in the store so blog pages will have proper content for each storeview.

How to upgrade extension

To upgrade the extension, follow these steps:

  1. Backup your store's database and web directory.
  2. Login to your server's SSH console and navigate to the root directory of the Magento 2 store.
  3. Run command composer require mirasvit/module-blog-mx:* --update-with-dependencies to update current extension with all dependencies.

    Note

    There are some cases when the command above is not applicable; it is not possible when updating the current module; neither will it be applicable when upgrading all the Mirasvit modules in a bundle. In this case, the command above will be of no effect.

    Run instead composer update mirasvit/* command. It will update all Mirasvit modules installed in your store.

  4. Run command php -f bin/magento module:enable Mirasvit_Core Mirasvit_BlogMx to enable the extension.
  5. Run command php -f bin/magento setup:upgrade to install updates.
  6. Run command php -f bin/magento cache:clean to clean the cache.
  7. Deploy static view files

    rm -rf pub/static/*; rm -rf var/view_preprocessed/*; php -f bin/magento setup:static-content:deploy

Note

If you have the Hyva installed, run:

composer require mirasvit/module-blog-mx:* mirasvit/module-blog-mx-hyva:* --update-with-dependencies

Disabling the Extension

Temporarily Disable

To temporarily disable the extension please follow these steps:

  1. Login to your server's SSH console and navigate to the root directory of the Magento 2 store.
  2. Run command php -f bin/magento module:disable Mirasvit_BlogMx to disable the extension.
  3. Log in to the Magento backend and refresh the store cache (if enabled).

Note

If you have Hyva installed, run:

php -f bin/magento module:disable Mirasvit_BlogMx Hyva_MirasvitBlogMx

Removing the Extension

To uninstall the extension, please follow these steps:

  1. Login to your server's SSH console and navigate to the root directory of the Magento 2 store.
  2. Run the command composer remove mirasvit/module-blog-mx to remove the extension.
  3. Log in to the Magento backend and refresh the store's cache (if enabled).

Note

If you have Hyva installed, run:

composer remove mirasvit/module-blog-mx:* mirasvit/module-blog-mx-hyva:*

Change Log

2.0.22

(2024-02-21)

Improvements

  • Autofilling related posts by tags if there are fewer posts than the limit
  • Prevent adding widgets to irrelevant pages (where those widgets have no content)
  • Improved posts grid in the admin panel

Fixed

  • Fixed the issue with the post data not being saved when attempting to assign the post to the category from a different store

2.0.21

(2024-01-29)

Improvements

  • Added estimated read time
  • Added reading progress bar

2.0.20

(2024-01-25)

Fixed

  • Issue with the number of views if Hide Duplicate settings is Yes

2.0.19

(2024-01-23)

Fixed

  • Issue with updating the number of views

2.0.18

(2024-01-22)

Improvements

  • Added template for Sidebar posts with slider
  • Posts as cards template displays a slider if the number of posts exceeds 2

2.0.17

(2024-01-10)

Fixed

  • Fixed the issue with 'Only related posts' filter not working as expected
  • Fixed the issue with the comments widget

2.0.16

(2024-01-05)

Fixed

  • Pagination on search results page

2.0.15

(2024-01-04)

Fixed

  • Alt text for Featured Image

2.0.14

(2023-12-22)

Fixed

  • Incorrect links to posts/categories if they are available on several stores
  • Issue creating a new category

2.0.13

(2023-12-18)

Fixed

  • Subscription form in footer

2.0.12

(2023-12-15)

Improvements

  • Hide unused fields in the root category edit form

Fixed

  • Sitemap
  • Display blog name instead of root category name

2.0.11

(2023-12-14)

Fixed

  • 1column layout

2.0.10

(2023-12-13)

Improvements

  • Settings for hide/show duplicate posts

2.0.9

(2023-12-05)

Fixed

  • Compatibility with php8.2

2.0.8

(2023-11-24)

Fixed

  • Page title
  • CSS style of related products widget for mobile devices

2.0.7

(2023-11-08)

Fixed

  • Issue with duplicating a search phrase from the blog search bar into the main search bar
  • Translation of publication date

2.0.6

(2023-10-24)

Features

  • Show posts from all child categories in a category

2.0.5

(2023-10-19)

Fixed

  • Applying a custom template

2.0.4

(2023-10-12)

Improvements

  • CSS classes by template type added to widgets' templates

2.0.3

(2023-10-11)

Improvements

  • Page and Widget types' labels in Layout Editor

Fixed

  • Fixed the issue with Rich Snippets for blog posts
  • Fixed the issue with posts' OpenGraph tags

2.0.2

(2023-10-05)

Improvements

  • AddThis sharing buttons replaced with AddToAny sharing buttons
  • Small improvements in Categories and Posts grids

2.0.1

(2023-10-04)

Improvements

  • Templates preview

2.0.0

(2023-09-29)

Features

  • Layout Editor
  • Widget-based frontend blog pages

Notice

  • Frontend pages of the blog are now built using Magento Widgets
  • All blocks on blog frontend pages are widgets
  • All old widget classes are removed from the extension and all existing blog widgets will be removed from the store during the extension's update
  • Templates' customizations of the extension prior to version 2.0.0 will no longer work but should not cause any issues

1.3.2

(2023-08-25)

Fixed

  • Links to categories in the menu

1.3.1

(2023-07-07)

Fixed

  • Content checker

1.3.0

(2023-07-07)

Improvements

  • Redesign

Fixed

  • Widget option "Display post images" not working

1.2.25

(2023-06-21)

Improvements

  • Ability to choose url suffix (none, slash, custom)

Fixed

  • Pagination

1.2.24

(2023-05-03)

Improvements

  • Added website to author's social profiles

1.2.23

(2023-04-24)

Fixed

  • Scoring for the first keyword

1.2.22

(2023-03-13)

Improvements

  • Removed inline post editor

Fixed

  • Issue with deleting author

1.2.21

(2023-01-26)

Improvements

  • Increased maximum content size to 16MB
  • Added support of Magento 2.4.6

Fixed

  • Assign post to Root Category by default

1.2.20

(2022-12-26)

Fixed

  • Translation "About author"
  • Displaying a disabled category

1.2.19

(2022-12-22)

Improvements

  • Thumbnail Size settings

Fixed

  • Mass action Change status

1.2.18

(2022-12-09)

Fixed

  • Filter by store in sitemap

1.2.17

(2022-12-08)

Features

  • Add posts and categories to sitemap

1.2.16

(2022-11-24)

Fixed

  • Issue with blank preview page when reopening.
  • Page not found for Post/Category in first level if option Use subcategories is enabled.
  • Pagination
  • Double slash in url

1.2.15

(2022-10-24)

Features

  • Use subcategories in Url

1.2.14

(2022-09-30)

Fixed

  • Category is not visible in any store where this post is visible

1.2.13

(2022-09-22)

Fixed

  • Compatibility with php8.1

1.2.12

(2022-09-19)

Fixed

  • Compatibility with Page Builder

1.2.11

(2022-09-08)

Fixed

  • Issue with root category

1.2.10

(2022-08-04)

Fixed

  • Category links in breadcrumbs

1.2.9

(2022-07-27)

Improvements

  • Ability to use different base urls for different store views

1.2.8

(2022-07-05)

Fixed

  • Disabled the ability to change the position of an element in Related Posts and Related Products on the post edit page.

1.2.7

(2022-07-04)

Fixed

  • "Table or view not found" error on update.

1.2.6

(2022-06-29)

Fixed

  • Preventing the creation of unused tables during installation

1.2.5

(2022-06-23)

Improvements

  • Ability to disable Related Posts on Product page

1.2.4

(2022-06-20)

Improvements

  • remove db_schema_whitelist.json

1.2.3

(2022-06-14)

Fixed

  • Fixed the issue with categories and posts not migrated from eav tables

1.2.2

(2022-06-01)

Fixed

  • Public access to the draft is forbidden

1.2.1

(2022-05-25)

Fixed

  • Issue with Add Related Products if more than one Inventory Source is configured

1.2.0

(2022-05-23)

Improvements

  • migrate to declarative schema

1.1.28

(2022-05-12)

Fixed

  • Dependencies

1.1.27

(2022-05-10)

Fixed

  • Issue on Post page when using cache

1.1.26

(2022-05-09)

Fixed

  • Issue with Related Products block style
  • Compatibility with Magento 2.3.3. and below

1.1.25

(2022-04-08)

Fixed

  • RSS filter by category

1.1.24

(2022-04-05)

Improvements

  • Reduced thumbnail size

1.1.23

(2022-02-14)


1.1.22

(2022-02-14)

Fixed

  • Issue after delete category

1.1.21

(2022-02-04)

Fixed

  • Image alt tag

1.1.20

(2022-01-27)

Improvements

  • Style

1.1.19

(2022-01-27)

Fixed

  • Issue with content checking

1.1.18

(2022-01-21)

Features

  • Sorting posts by update date
  • Views counter

Improvements

  • Content checker

1.1.17

(2022-01-18)

Features

  • Rich snippet

Improvements

  • Added meta keywords

Fixed

  • Pagination style

1.1.16

(2021-12-17)

Improvements

  • Checking fields

1.1.15

(2021-12-15)

Fixed

  • Issue with editing post tags

1.1.14

(2021-12-08)

Fixed

  • Issue with post save if Single-Store Mode is enabled

1.1.13

(2021-10-20)

Fixed

  • Compatibility with Magento Page Builder

1.1.12

(2021-09-29)

Improvements

  • compatibility with third party Page Builder

1.1.11

(2021-09-20)

Fixed

  • Issue when changing status via massaction for Magento 2.3

1.1.10

(2021-09-14)

Fixed

  • Issue wiht rss

1.1.9

(2021-09-14)

Fixed

  • Issue when changing status via massaction

1.1.8

(2021-09-07)

Fixed

  • Issue with Page Buider for Magento 2.4.3

1.1.7

(2021-06-30)

Fixed

  • Issue after delete author,post,category
  • Issue after save author,post,category

1.1.6

(2021-06-15)

Fixed

  • Clean cache on post/category/author save/delete

1.1.5

(2021-06-09)

Fixed

  • Fixed the issue with upgrading extension from free Blog extension

1.1.4

(2021-06-04)

Improvements

  • Added id and sort order columns on categories page

Fixed

  • Issue with display post if featured image not set

1.1.3

(2021-05-25)

Improvements

  • Ability to enable/disable link in the footer

1.1.2

(2021-05-14)

Fixed

  • Fixed the issue with not displayed selected store in tag form if 'All Store Views' selected

1.1.1

(2021-04-29)

Fixed

  • Magento EE PageBuilder compatibility

1.1.0

(2021-04-27)

Features

  • Ability to manage Authors
  • Ability to manage Tags
  • Full multistore support (Posts, Categories, Authors, Tags)
  • Different display modes for post and post list pages
  • New widgets (2 types, old widgets will be removed)
  • Ability to duplicate posts
  • Open Graph meta tags for posts (generated automatically)

1.0.6

(2021-02-15)

Fixed

  • rss
  • save post without date

1.0.5

(2021-01-19)

Fixed

  • Minor fixes

1.0.4

(2021-01-16)

Fixed

  • Issue with templates

1.0.3

(2020-12-31)

Fixed

  • Stored "Store View" does not show in the form (m2.4.1)

1.0.2

(2020-12-30)

Fixed

  • Error "Type Error occurred when creating object: Mirasvit\BlogMx\Block\Catalog\RelatedPosts ..."
  • Error "TypeError: Return value of Mirasvit\BlogMx\Model\ConfigProvider::getCommentProvider() ..."

1.0.1

(2020-12-18)

Fixed

  • Minor fixes

1.0.0

(2020-12-11)

Features

  • Initial release