]> scripts.mit.edu Git - autoinstalls/wordpress.git/blob - wp-content/themes/twentyfifteen/content.php
WordPress 4.5
[autoinstalls/wordpress.git] / wp-content / themes / twentyfifteen / content.php
1 <?php
2 /**
3  * The default template for displaying content
4  *
5  * Used for both single and index/archive/search.
6  *
7  * @package WordPress
8  * @subpackage Twenty_Fifteen
9  * @since Twenty Fifteen 1.0
10  */
11 ?>
12
13 <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
14         <?php
15                 // Post thumbnail.
16                 twentyfifteen_post_thumbnail();
17         ?>
18
19         <header class="entry-header">
20                 <?php
21                         if ( is_single() ) :
22                                 the_title( '<h1 class="entry-title">', '</h1>' );
23                         else :
24                                 the_title( sprintf( '<h2 class="entry-title"><a href="%s" rel="bookmark">', esc_url( get_permalink() ) ), '</a></h2>' );
25                         endif;
26                 ?>
27         </header><!-- .entry-header -->
28
29         <div class="entry-content">
30                 <?php
31                         /* translators: %s: Name of current post */
32                         the_content( sprintf(
33                                 __( 'Continue reading %s', 'twentyfifteen' ),
34                                 the_title( '<span class="screen-reader-text">', '</span>', false )
35                         ) );
36
37                         wp_link_pages( array(
38                                 'before'      => '<div class="page-links"><span class="page-links-title">' . __( 'Pages:', 'twentyfifteen' ) . '</span>',
39                                 'after'       => '</div>',
40                                 'link_before' => '<span>',
41                                 'link_after'  => '</span>',
42                                 'pagelink'    => '<span class="screen-reader-text">' . __( 'Page', 'twentyfifteen' ) . ' </span>%',
43                                 'separator'   => '<span class="screen-reader-text">, </span>',
44                         ) );
45                 ?>
46         </div><!-- .entry-content -->
47
48         <?php
49                 // Author bio.
50                 if ( is_single() && get_the_author_meta( 'description' ) ) :
51                         get_template_part( 'author-bio' );
52                 endif;
53         ?>
54
55         <footer class="entry-footer">
56                 <?php twentyfifteen_entry_meta(); ?>
57                 <?php edit_post_link( __( 'Edit', 'twentyfifteen' ), '<span class="edit-link">', '</span>' ); ?>
58         </footer><!-- .entry-footer -->
59
60 </article><!-- #post-## -->