Adding recent posts to a page
One of the problems with the ‘recent posts’ option for your homepage is the inability to add content.This has nothing to do with the theme, it’s just how WordPress works.
But WordPress does have a neat built in function that lets you display recent posts anywhere you want.
To use this on the Tradesman Theme add the [recentposts] shortcode to a new page above, below or in between your content. You will then see the list of recent posts like this:
I’ve limited the number of posts on this demo page using a shortcode attribute: [recentposts numberposts=3]. The default is 9 posts on a page.
If you want to link to pages as well as posts the shortcode format is: [recentposts pages=116,25,188]
To find the ID number of the post or page you want to display:
- View the list of posts or page in your dashboard
- Edit the page you want to display
- Look in the address bar at the top of the screen and you will see something like: post=317.
- Copy the post number into the shortcode.
The example below has two pages and a post. Note the placeholder for the pages without a featured image: