简体   繁体   中英

Wordpress Blog Post are not displaying in custum theme

I am working on a Woocommerce site, and i am using Mystile(customize) theme for it. I added a page name Blog and want to show all the post here, how do i do this. I am not using static pages so Setting -> Reading will not work for me. I also tried Page Attribute 'Blog'(template-blog.php a default file in Mystile theme)but it's not work.

You need to iterate through the posts:

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

Then print the articles in the format you want..

Make sure you are using WordPress Loop?? https://codex.wordpress.org/The_Loop

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM