Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Wordpress: How to get Blog Posts on a 'Page' called blog?

Featured Replies

I know the normal way to do this would be to set the 'posts page' to the Blog page within the wp-admin readining settings, but i have to leave this blank as i have categories setting the posts to go to all sorts of posts:-

 

Accessories

- Hats

- Shoes

- Etc

 

But i also need to intergrate a Blog. My Blog is a Page found on the main navigation, but i dont know how to get 'blog posts' only to go to this specific Blog Page? As i cant add categories like you can for the posts?

 

Any ideas?

 

Probably a simple answer?

  • Author

I hate to say this, but I don't understand the question. I got confused about half-way through.

 

Take a break for a few minutes and figure out how you would explain it to your mom. And have a pint to take the edge off: it'll help.

 

Moron!

Let's try and keep things civil folks. If you can't help the OP, then perhaps it's best to refrain from posting in this thread - and please try to refrain from calling each other names. WDF just ain't that kind of party!

First thing is copy your index.php into a new file and call it blog-template.php

 

At the top of the file add the following:

 

<?php
/*
Template Name: Blog Template
*/
?>

 

Now we need to edit the wordpress code, find the following:

 

<?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>

 

Add the following in front of that

 

<?php query_posts('category_name=category'); ?>

 

Look for this code:

 

<?php endif; ?>

 

Add the following after it

 

<?php wp_reset_query(); ?>

 

Change category to the name of the blog category.

 

Now upload the file to your theme files e.g. /wp-content/themes/theme-name.

 

Now go to your blog page, and on the right hand side it will say template: Use the drop down and find the blog template. Save that and now any posts made in the blog category will appear on that page.

 

Hope that helps

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.