mirror of
https://github.com/WordPress/five-for-the-future.git
synced 2025-07-02 01:01:18 +03:00
Use the post-type when choosing template partial
This commit is contained in:
parent
847e99f44e
commit
3847e83cf3
|
@ -26,23 +26,19 @@ get_header(); ?>
|
||||||
while ( have_posts() ) :
|
while ( have_posts() ) :
|
||||||
the_post();
|
the_post();
|
||||||
|
|
||||||
/*
|
get_template_part( 'template-parts/content', get_post_type() );
|
||||||
* 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( 'template-parts/content', 'page' );
|
|
||||||
|
|
||||||
endwhile;
|
endwhile;
|
||||||
|
|
||||||
the_posts_pagination();
|
the_posts_pagination();
|
||||||
|
|
||||||
else :
|
?>
|
||||||
|
|
||||||
|
<?php else :
|
||||||
|
|
||||||
get_template_part( 'template-parts/content', 'none' );
|
get_template_part( 'template-parts/content', 'none' );
|
||||||
|
|
||||||
endif;
|
endif; ?>
|
||||||
?>
|
|
||||||
|
|
||||||
</main><!-- #main -->
|
</main><!-- #main -->
|
||||||
|
|
||||||
|
|
|
@ -9,7 +9,7 @@ get_header(); ?>
|
||||||
<?php while ( have_posts() ) :
|
<?php while ( have_posts() ) :
|
||||||
the_post();
|
the_post();
|
||||||
|
|
||||||
get_template_part( 'template-parts/plugin', 'single' );
|
get_template_part( 'template-parts/content', get_post_type() );
|
||||||
endwhile; ?>
|
endwhile; ?>
|
||||||
|
|
||||||
</main><!-- #main -->
|
</main><!-- #main -->
|
||||||
|
|
Loading…
Reference in a new issue