Latest Posts

A popular item to have on a website is your latest news items – probably in a summary format. What you ideally want is for these to generates automatically, so when you add a new item you don’t have the additional work of also updating the home page. Well, WordPress has blocks that do just that!

Option One: Feed

On the page you want to add you latest news to go to the block menu. Select the ‘Patterns’ tab and then ‘Posts’. For this tutorial we are going to use the first option in the previews ‘Standard’ but you can scroll down and explore options.

Screenshot of wp-admin area showing how to select the post feed

When this gets added to the page it will be in the default ‘List View’ which displays it as one column.

Screenshot of wp-admin area showing the in-block controls with List View selected

For our purposes we want three columns, so we switch to ‘Grid View’.

Screenshot of wp-admin area showing in-block controls with Grid View selected.

What if you want more control over what gets displayed? The block settings allow you to change the order, and whether to include, exclude or only show sticky posts.

Screenshot of wp-admin area showing Query block settings for sticky posts

The controls also have filters, the one you would most likely use is Taxonomies (taxonomies in WordPress is the fancy name for categories and tags).

Screenshot of wp-admin area showing Query block settings for Taxonomies

Once Taxonomies is selected you can then enter the categories / tags you want to be displayed.

Screenshot of wp-admin area showing Filter option in Query block settings

What if you wanted four (or two) columns instead of the default three? You will find those controls in the block itself.

Screenshot of wp-admin area showing in-block controls for query display

Option two: Latest Posts block

This block will achieve the same result, some of the controls are a little different.

Screenshot of wp-admin area with Latest Posts block indicated

Again the first thing we are going to do is change to the grid view so that the content is displayed in three columns.

Screenshot of wp-admin area showing Grid View selected in the in-block settings

To control what get shown you can adjust the block settings.

Screenshot of wp-admin area showing the block settings for the Latest Posts block

At the bottom of the block settings are the controls for how many items and columns are to be displayed.

Screenshot of wp-admin area showing the number of items / columns controls in the block settings

And that’s it! Two ways on how you can dynamically show new posts you make in the front page, which keeps this page up-to-date without any additional work.

Should you need assistance setting up the Latest Posts feed, or any other aspect of WordPress, the Web Team at Nerd Crossing are here to help!