Advertisement
rexcoder

Archive Page

Jan 5th, 2015
197
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.17 KB | None | 0 0
  1. //Customized Archive.php page from underscore theme--------------------------------------------------------
  2. if ( is_category() ) :
  3.     printf( __( 'Posts in the ', 'my-simone' ) );
  4.     echo '<em>';
  5.     single_cat_title();
  6.     echo '</em> ' . __('category', 'my-simone') . ':';
  7.  
  8. elseif ( is_tag() ) :
  9.     printf( __( 'Posts with the ', 'my-simone' ) );
  10.     echo '<em>';
  11.     single_tag_title();
  12.     echo '</em> ' . __('tag', 'my-simone') . ':';
  13.  
  14. elseif ( is_author() ) :
  15.     printf( __( 'Author: %s', 'my-simone' ), '<span class="vcard">' . get_the_author() . '</span>' );
  16.  
  17. elseif ( is_day() ) :
  18.     printf( __( 'Posts from %s', 'my-simone' ), '<span>' . get_the_date() . '</span>' );
  19.  
  20. elseif ( is_month() ) :
  21.     printf( __( 'Posts from %s', 'my-simone' ), '<span>' . get_the_date( _x( 'F Y', 'monthly archives date format', 'my-simone' ) ) . '</span>' );
  22.  
  23. elseif ( is_year() ) :
  24.     printf( __( 'Posts from %s', 'my-simone' ), '<span>' . get_the_date( _x( 'Y', 'yearly archives date format', 'my-simone' ) ) . '</span>' );
  25.  
  26. elseif ( is_tax( 'post_format', 'post-format-aside' ) ) :
  27.     _e( 'Asides', 'my-simone' );
  28.  
  29. else :
  30.     _e( 'Archives', 'my-simone' );
  31.  
  32. endif;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement