Recent posts on front page, older on blog page
My clients wants her 5 most recent posts on front page and a blog page with the rest. Can't figure out how to do this. Any suggestions?
|
You could probably use the List Category Posts plugin with an offset attribute to show all the posts except for the first five on a blog page. Then set the home page to show latest posts in Settings>Reading and set this to show 5 posts in the theme settings.
I'm not certain about how exact those instructions are but when setting it up it should be clear. |
You could use something like the TPG Get Posts plugin to do that. https://wordpress.org/plugins/tpg-get-posts/
Advantage: You can embed other content on the main page before/after the posts. I use a similar (but older) plugin on one site so we have a tiny blurb before the 3 most recent posts on the main page. |
Thanks very much. I'm trying both. Having more luck with TPG Get Posts. I'm able to display the first 5 most recent posts on the front page (with some formatting problems). But don't know how to omit the first 5 posts on the blog page.
|
You could try using the 'Multi column/custom query' template supplied with the theme. Create a page that you would use as your blog page and use the 'offset' parameter in the query. This may cause a problem with the pagination. Read the linked article about that and you may have to do some customizaton of the template.
|
Thanks Juggledad. I see how that works but don't know where to add the offset query ($query = new WP_Query( array( 'offset' => 3 ) );). I'm not a coder.
|
If you use the template you can put it in the custom query - go read the thread: 'TEMPLATE: Multi Column/Custom Query' in the Gold Forum>>Tutorials
|
All times are GMT -6. The time now is 02:48 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.