archive.php 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. <?php
  2. /**
  3. * The template for displaying archive pages.
  4. *
  5. * Learn more: http://codex.wordpress.org/Template_Hierarchy
  6. *
  7. * @package Canard
  8. */
  9. get_header(); ?>
  10. <div class="site-content-inner">
  11. <div id="primary" class="content-area">
  12. <main id="main" class="site-main" role="main">
  13. <?php if ( have_posts() ) : ?>
  14. <header class="page-header">
  15. <?php
  16. the_archive_title( '<h1 class="page-title">', '</h1>' );
  17. the_archive_description( '<div class="taxonomy-description">', '</div>' );
  18. ?>
  19. </header><!-- .page-header -->
  20. <?php /* Start the Loop */ ?>
  21. <?php while ( have_posts() ) : the_post(); ?>
  22. <?php
  23. /* Include the Post-Format-specific template for the content.
  24. * If you want to override this in a child theme, then include a file
  25. * called content-___.php (where ___ is the Post Format name) and that will be used instead.
  26. */
  27. get_template_part( 'content', get_post_format() );
  28. ?>
  29. <?php endwhile; ?>
  30. <?php the_posts_navigation(); ?>
  31. <?php else : ?>
  32. <?php get_template_part( 'content', 'none' ); ?>
  33. <?php endif; ?>
  34. </main><!-- #main -->
  35. </div><!-- #primary -->
  36. <?php get_sidebar(); ?>
  37. </div><!-- .site-content-inner -->
  38. <?php get_footer(); ?>