使用下面loop只能展示当前分类下的文章
<?php if(have_posts()): ?>
<?php while(have_posts()):the_post();?>
如果要展示所有文章则需要用到WP_Query 示例
<?php
$args = array(
'post_type'=>'post'
);
//
$query = new WP_Query($args);
?>
<?php if($query->have_posts()): ?>
<?php while($query->have_posts()):$query->the_post();?>
<li>
<div class="blogImg">
<?php the_post_thumbnail()?>
<div class="blog_date"><?php the_time('M,d,Y')?></div>
</div>
<div class="blog_sec">
<h3><a href="<?php the_permalink();?>"><?php the_title();?></a></h3>
<p><?php the_excerpt();?></p>
<div class="readmore"><a href="#">Read</a></div>
</div>
</li>
<?php endwhile; endif; wp_reset_postdata();?>