This is a pro block and requires activation of Gutenify Pro. Please refer to the Gutenify Pro page for more information.
To view live demo of post filter, kindly visit on the provided link. Related Post (Extended) Demo
The Related Posts block allows to display a selection of posts that are related to the current post being viewed. This block is particularly useful for keeping visitors engaged on your website by providing them with additional content that they may find interesting based on the topic of the current post.
How to Add Related Post? #
So, to add the related post block into your website just go to WordPress dashboard menu → Posts →Add New.
Note: Select the post, page or products where you want to add related post block.
Initially, you will see related posts categorized accordingly, with the option to adjust settings afterward.
You can customize the Post Type to display related posts according to your specific needs, choosing from options such as posts, pages, and products.
To edit the related post block, you will have the options in right sidebar.
- Layout
- Settings
- Options Settings
- Advance
Layout #
Layout settings generally refers to the options and configurations available to control the visual arrangement and appearance of content on a webpage or within a specific block.
Settings #
Within this setting, you will find options in dropdown to select the Post Type (Post, Page, or Products), along with a “Force Reload” toggle button.
Post: If the post is chosen under the Post Type, only the related post’s content will appear in the related post block.
Page: If the page is chosen under the Post Type, only the related pages will appear in the related post block.
Products: If the products is chosen under the Post Type , only the related products will appear in the related post block.
(Please note that this option will be available only if WooCommerce is activated.)
Force Reload: The “Force Reload” toggle button, when clicked, updates the related post block according to the selected Post Type (Post, Page, or Products). This action ensures that the most current content is fetched and displayed, reflecting any recent changes or updates made to the chosen post type.
Options Settings #
In the options settings, you’ll find Taxonomy, Order, and Post Meta Query settings.
Taxonomy #
Depending on the selected Post Type, you can choose between categories and tags in the Taxonomy settings. For instance, if you select “Products” as the Post Type, options for product categories and product tags will be available. However, if you choose “Pages” as the Post Type, taxonomy options will not be accessible. For “Posts” as the Post Type, categories and tags in taxonomy will both be visible.
Order #
You have the option to display related posts in either ascending or descending order, based on the date or title.
Post Meta Query #
The meta key feature in related post blocks refers to a custom field or identifier used to establish relationships between different posts. You can add multiple meta keys by clicking “Add Meta Queries” to display the most relevant posts, pages, or products. When two or more queries are added, you’ll have an additional option called “Query Relationship,” which includes “AND” and “OR” as options for refining the relationship between queries.
AND: All meta queries must match for a post to be displayed in related posts. This means that the post must satisfy the conditions of all specified meta queries to be considered related.
OR: If any one of the meta queries matches, the post will be displayed in related posts. This option broadens the scope, allowing posts to be related if they meet the criteria of at least one of the specified meta queries.
After opening the meta key section, you will find options to specify:
Meta Key #
A “meta key” refers to a specific identifier used to store custom metadata associated with posts, pages, or products.
Meta Value #
A “meta value” refers to the actual data stored within a specific meta key associated with a post, page, or products.
Meta Compare #
A “meta compare” is a parameter used in queries to compare the value of a meta key against a specified value. We have different compare parameter available like Equals to(=), Not Equals to(!=), Greater than(>), Less than(<) etc. so you can choose and display the most related posts.
Following the image above, only posts, pages, or products that share the same category and have a meta query related to Paris will be displayed in the Related Post section.
Advance #
In the Advanced settings, Gutenify offers responsive options to add extra space to your widgets and the ability to hide content on smaller devices. It also includes custom CSS capabilities for enhancing your website’s design.
Learn more Here
When you’re satisfied with your related post block, click “Publish”. Simply repeat the same procedure to add more blocks to your posts or pages.
Output after adding Related Post #
Below output is of same Category: water and same meta query of Destination = Paris.