admin管理员组

文章数量:1420174

I am trying to make a Wordpress theme. In my theme, there are multiple post formats and all are rendered on the index.php something like this website www.theoutline It has a 1st section with single and as you scroll it has more than one post on other section and the same format goes on till the end of the page. Here I am confused about how to achieve this. Do I need to make another query for them or is there any other way. Please let me know if there is any way to do this.

I am query posts like this.

<?php
        if(have_posts()): ?> 
            <div class="row">
            <?php while(have_posts()): the_post(); ?>

                <?php get_template_part('template-parts/content', get_post_format());?>

            <?php endwhile;wp_reset_postdata(); ?>
            </div>

        <?php else: ?>


            <?php get_template_part('/template-parts/content', 'none');?>

        <?php endif
        ?>

本文标签: phpHow can I render more than multiple posts on templateparts with post formats