WordPress 4.7
[autoinstalls/wordpress.git] / wp-content / themes / twentyseventeen / single.php
1 <?php
2 /**
3  * The template for displaying all single posts
4  *
5  * @link https://developer.wordpress.org/themes/basics/template-hierarchy/#single-post
6  *
7  * @package WordPress
8  * @subpackage Twenty_Seventeen
9  * @since 1.0
10  * @version 1.0
11  */
12
13 get_header(); ?>
14
15 <div class="wrap">
16         <div id="primary" class="content-area">
17                 <main id="main" class="site-main" role="main">
18
19                         <?php
20                                 /* Start the Loop */
21                                 while ( have_posts() ) : the_post();
22
23                                         get_template_part( 'template-parts/post/content', get_post_format() );
24
25                                         // If comments are open or we have at least one comment, load up the comment template.
26                                         if ( comments_open() || get_comments_number() ) :
27                                                 comments_template();
28                                         endif;
29
30                                         the_post_navigation( array(
31                                                 'prev_text' => '<span class="screen-reader-text">' . __( 'Previous Post', 'twentyseventeen' ) . '</span><span aria-hidden="true" class="nav-subtitle">' . __( 'Previous', 'twentyseventeen' ) . '</span> <span class="nav-title"><span class="nav-title-icon-wrapper">' . twentyseventeen_get_svg( array( 'icon' => 'arrow-left' ) ) . '</span>%title</span>',
32                                                 'next_text' => '<span class="screen-reader-text">' . __( 'Next Post', 'twentyseventeen' ) . '</span><span aria-hidden="true" class="nav-subtitle">' . __( 'Next', 'twentyseventeen' ) . '</span> <span class="nav-title">%title<span class="nav-title-icon-wrapper">' . twentyseventeen_get_svg( array( 'icon' => 'arrow-right' ) ) . '</span></span>',
33                                         ) );
34
35                                 endwhile; // End of the loop.
36                         ?>
37
38                 </main><!-- #main -->
39         </div><!-- #primary -->
40         <?php get_sidebar(); ?>
41 </div><!-- .wrap -->
42
43 <?php get_footer();