Posts
The [post]
shortcode can be used to display a secondary loop of posts anywhere using WP_Query
.
Classes |
| ||||||||
query | WordPress query string or keyword (Available keywords: related). | ||||||||
template | Custom template name. Template file must reside in the (child) theme's templates directory and be prefixed with loop- (ex. templates/loop-list ). | ||||||||
excerpt | Custom excerpt length (number of words). Set to 0 to disable excerpts. (Default: 55) | ||||||||
thumbnail | Custom thumbnail image size (none|thumbnail|small|medium|large|full). (Default: medium) | ||||||||
header | Posts header size (tiny|small|medium|large|huge). (Default: small) | ||||||||
meta | Info displayed below post title. (date_author|timeago_author|date|timeago|author|none) | ||||||||
tags | Set to false to disable tags (categories, tags and sticky post indicator). | ||||||||
read_more | Set to false to disable the "Read more" link. | ||||||||
pagination | Set to true to enable pagination. | ||||||||
pagination_alignment | Pagination alignment (left|center|right). | ||||||||
pagination_menu | Additional classes for the pagination menu. | ||||||||
next | Pagination next posts link text (default: "Older posts"). | ||||||||
prev | Pagination previous posts link text (default: "Newer posts"). | ||||||||
count | Specify post count when query is a keyword (default: 4). | ||||||||
header_text | Header text to display above posts (only displayed if there are posts). | ||||||||
header_classes | Classes for the header. | ||||||||
content_before | Content before the posts (only displayed if there are posts). | ||||||||
content_after | Content after the posts (only displayed if there are posts). |
<posts items query="posts_per_page=3&ignore_sticky_posts=1">
<posts divided items query="posts_per_page=3&ignore_sticky_posts=1">
<posts very relaxed items query="posts_per_page=3&ignore_sticky_posts=1">
<posts grid query="posts_per_page=3&ignore_sticky_posts=1">
<posts divided two column grid query="posts_per_page=4&ignore_sticky_posts=1">
<posts celled two column grid query="posts_per_page=6&ignore_sticky_posts=1">


Update Theme and Plugins from Zip
Update Theme and Plugins from Zip File is a good quality of life plugin that allows to update/roll back your current theme or plugins by simply uploading them as if they weren’t already installed. By default WordPress doesn’t provide such functionality – when you upload a .zip file for a plugin that is already installed…

Adding a custom attribute to Gutenberg block
Using Gutenberg Block Filters to add an editable rel attribute to the core Button block.

Blank template
Creating a blank page template file without any header, footer or sidebars.
Breadcrumb NavXT
Setting up the NavXT breadcrumbs plugin to display breadcrumbs with Semantic UI breadcrumb component styling.

<posts internally celled two column grid query="posts_per_page=6&ignore_sticky_posts=1&meta_key=_thumbnail_id">

Font Awesome SVG
Documentation of the Font Awesome SVG icon theme.

Update Theme and Plugins from Zip
Update Theme and Plugins from Zip File is a good quality of life plugin that allows to update/roll back your current theme or plugins by simply uploading them as if they weren’t already installed. By default WordPress doesn’t provide such functionality – when you upload a .zip file for a plugin that is already installed…

Adding a custom attribute to Gutenberg block
Using Gutenberg Block Filters to add an editable rel attribute to the core Button block.
<posts cards query="posts_per_page=3&ignore_sticky_posts=1&meta_key=_thumbnail_id">
<posts four stackable cards query="posts_per_page=4&ignore_sticky_posts=1">
<posts divided items query="posts_per_page=3&ignore_sticky_posts=1" pagination="true">
<posts two column grid
query="posts_per_page=4"
pagination="true"
next="Older entries"
prev="Newer entries"
pagination_alignment="right"
pagination_menu="tiny secondary"
>
<posts one column vertically divided grid
query="posts_per_page=1&ignore_sticky_posts=1"
template="templates/loop-content"
pagination="true"
next="Older post"
prev="Newer post"
>
<posts items query="posts_per_page=3&ignore_sticky_posts=1" header="huge">
Update Theme and Plugins from Zip
Update Theme and Plugins from Zip File is a good quality of life plugin that allows to update/roll back your…
Adding a custom attribute to Gutenberg block
Using Gutenberg Block Filters to add an editable rel attribute to the core Button block.
<posts three column grid query="posts_per_page=3&ignore_sticky_posts=1&meta_key=_thumbnail_id" excerpt="20" thumbnail="none">
<posts three column grid query="posts_per_page=3&ignore_sticky_posts=1&meta_key=_thumbnail_id" excerpt="0">


Update Theme and Plugins from Zip
Update Theme and Plugins from Zip File is a good quality of life plugin that allows to update/roll back your…

Adding a custom attribute to Gutenberg block
Using Gutenberg Block Filters to add an editable rel attribute to the core Button block.
<posts three column grid query="posts_per_page=3&ignore_sticky_posts=1&meta_key=_thumbnail_id" excerpt="20" meta="false">
<posts three column grid query="posts_per_page=3&ignore_sticky_posts=1&meta_key=_thumbnail_id" excerpt="20" tags="false">


Update Theme and Plugins from Zip
Update Theme and Plugins from Zip File is a good quality of life plugin that allows to update/roll back your…

Adding a custom attribute to Gutenberg block
Using Gutenberg Block Filters to add an editable rel attribute to the core Button block.
<posts three column grid query="posts_per_page=3&ignore_sticky_posts=1&meta_key=_thumbnail_id" excerpt="20" read_more="false">
<subheader dividing>More posts</subheader>
<posts compact marginless items query="posts_per_page=5&ignore_sticky_posts=1" header="tiny" excerpt="0" thumbnail="none" meta="true" tags="false" read_more="false">
<posts query="related" count="5">
<posts items query="posts_per_page=3&ignore_sticky_posts=1" header_text="Header shown when there are posts" header_classes="large dividing">
<posts items query="posts_per_page=3&cat=123123" header_text="Header not shown because there are no posts">
header_text
argument for only when there are results.<posts items query="posts_per_page=3&ignore_sticky_posts=1" content_before="{lt}div class='ui primary segment'{gt}" content_after="{lt}/div{gt}">
<posts items query="posts_per_page=3&cat=123123" content_before="{lt}div class='ui primary segment'{gt}" content_after="{lt}/div{gt}">
That way there won't be an empty container when there are no related posts for example.
<posts three column internally celled stackable grid query="related" count="6" header_text="Related posts" header_classes="large dividing" content_before="{lt}div class='ui segment'{gt}" content_after="{lt}/div{gt}">
Chap Theme -> Code -> After post content
can easily display related posts for all posts.