WordPress排版问题twentyfifteen首页做成列表主题形式 摘要完美显示

在你的Wordpress系统后台找到 index.php 再寻找中以下代码

本文章转自 科研动力
<?php
// Start the loop.
while ( have_posts() ) : the_post();
/*
* Include the Post-Format-specific template for the content.
* If you want to override this in a child theme, then include a file
* called content-___.php (where ___ is the Post Format name) and that will be used instead.
*/
get_template_part( 'content', get_post_format() );
// End the loop.
endwhile;

更改为以下代码。只是把content改为了content-search。

<?php
// Start the loop.
while ( have_posts() ) : the_post();
/*
* Include the Post-Format-specific template for the content.
* If you want to override this in a child theme, then include a file
* called content-___.php (where ___ is the Post Format name) and that will be used instead.
*/
get_template_part( 'content-search', get_post_format() );
// End the loop.
endwhile;
THE END