Advertisement
Guest User

Content

a guest
Jun 16th, 2013
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 3.06 KB | None | 0 0
  1. <?php
  2. /**
  3.  * The default template for displaying content. Used for both single and index/archive/search.
  4.  *
  5.  * @package WordPress
  6.  * @subpackage Twenty_Twelve
  7.  * @since Twenty Twelve 1.0
  8.  */
  9. ?>
  10.  
  11.     <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
  12.         <?php if ( is_sticky() && is_home() && ! is_paged() ) : ?>
  13.         <div class="featured-post">
  14.             <?php _e( 'Featured post', 'twentytwelve' ); ?>
  15.         </div>
  16.         <?php endif; ?>
  17.         <header class="entry-header">
  18.             <?php the_post_thumbnail(); ?>
  19.             <?php if ( is_single() ) : ?>
  20.             <h1 class="entry-title"><?php the_title(); ?></h1>
  21.             <?php else : ?>
  22.             <h1 class="entry-title">
  23.                 <a href="<?php the_permalink(); ?>" title="<?php echo esc_attr( sprintf( __( 'Permalink to %s', 'twentytwelve' ), the_title_attribute( 'echo=0' ) ) ); ?>" rel="bookmark"><?php the_title(); ?></a>
  24.             </h1>
  25.             <?php endif; // is_single() ?>
  26.    
  27.             <footer class="entry-meta">
  28.                 <?php twentytwelve_entry_meta(); ?>
  29.             </footer>  
  30.            
  31.             <?php if ( comments_open() ) : ?>
  32.                 <div class="comments-link">
  33.                     <?php comments_popup_link( '<span class="leave-reply">' . __( 'Please comment', 'twentytwelve' ) . '</span>', __( '1 Comment', 'twentytwelve' ), __( '% Comments', 'twentytwelve' ) ); ?>
  34.                 </div><!-- .comments-link -->
  35.             <?php endif; // comments_open() ?>
  36.         </header><!-- .entry-header -->
  37.  
  38.         <?php if ( is_search() ) : // Only display Excerpts for Search ?>
  39.         <div class="entry-summary">
  40.             <?php the_excerpt(); ?>
  41.         </div><!-- .entry-summary -->
  42.         <?php else : ?>
  43.         <div class="entry-content">
  44.             <?php the_content( __( 'Continue reading <span class="meta-nav">&rarr;</span>', 'twentytwelve' ) ); ?>
  45.             <?php wp_link_pages( array( 'before' => '<div class="page-links">' . __( 'Pages:', 'twentytwelve' ), 'after' => '</div>' ) ); ?>
  46.         </div><!-- .entry-content -->
  47.         <?php endif; ?>
  48.  
  49.         <footer class="entry-meta">
  50.             <?php twentytwelve_entry_meta(); ?>
  51.             <?php edit_post_link( __( 'Edit', 'twentytwelve' ), '<span class="edit-link">', '</span>' ); ?>
  52.             <?php if ( is_singular() && get_the_author_meta( 'description' ) && is_multi_author() ) : // If a user has filled out their description and this is a multi-author blog, show a bio on their entries. ?>
  53.                 <div class="author-info">
  54.                     <div class="author-avatar">
  55.                         <?php echo get_avatar( get_the_author_meta( 'user_email' ), apply_filters( 'twentytwelve_author_bio_avatar_size', 68 ) ); ?>
  56.                     </div><!-- .author-avatar -->
  57.                     <div class="author-description">
  58.                         <h2><?php printf( __( 'About %s', 'twentytwelve' ), get_the_author() ); ?></h2>
  59.                         <p><?php the_author_meta( 'description' ); ?></p>
  60.                         <div class="author-link">
  61.                             <a href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ); ?>" rel="author">
  62.                                 <?php printf( __( 'View all posts by %s <span class="meta-nav">&rarr;</span>', 'twentytwelve' ), get_the_author() ); ?>
  63.                             </a>
  64.                         </div><!-- .author-link -->
  65.                     </div><!-- .author-description -->
  66.                 </div><!-- .author-info -->
  67.             <?php endif; ?>
  68.         </footer><!-- .entry-meta -->
  69.     </article><!-- #post -->
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement