Advertisement
Guest User

Untitled

a guest
Jul 2nd, 2015
192
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?php /* Template Name: Homepage Template With Cat 3 */ ?>
  2.  
  3. <?php get_header(); ?>
  4.  
  5. <div class="content">
  6.  
  7. <div class="posts">
  8.  
  9. <div class="page-title section light-padding">
  10.  
  11. <div class="section-inner">
  12.  
  13. <h4><?php if ( is_day() ) : ?>
  14. <?php printf( __( 'Date: %s', 'radcliffe' ), '' . get_the_date() . '' ); ?>
  15. <?php elseif ( is_month() ) : ?>
  16. <?php printf( __( 'Month: %s', 'radcliffe' ), '' . get_the_date( _x( 'F Y', 'F = Month, Y = Year', 'radcliffe' ) ) ); ?>
  17. <?php elseif ( is_year() ) : ?>
  18. <?php printf( __( 'Year: %s', 'radcliffe' ), '' . get_the_date( _x( 'Y', 'Y = Year', 'radcliffe' ) ) ); ?>
  19. <?php elseif ( is_category() ) : ?>
  20. <?php printf( __( 'Category: %s', 'radcliffe' ), '' . single_cat_title( '', false ) . '' ); ?>
  21. <?php elseif ( is_tag() ) : ?>
  22. <?php printf( __( 'Tag: %s', 'radcliffe' ), '' . single_tag_title( '', false ) . '' ); ?>
  23. <?php elseif ( is_author() ) : ?>
  24. <?php $curauth = (isset($_GET['author_name'])) ? get_user_by('slug', $author_name) : get_userdata(intval($author)); ?>
  25. <?php printf( __( 'Author: %s', 'radcliffe' ), $curauth->display_name ); ?>
  26. <?php else : ?>
  27. <?php _e( 'Archive', 'radcliffe' ); ?>
  28. <?php endif; ?>
  29.  
  30. <?php
  31. $paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
  32.  
  33. if ( "1" < $wp_query->max_num_pages ) : ?>
  34.  
  35. <span><?php printf( __('(page %s of %s)', 'radcliffe'), $paged, $wp_query->max_num_pages ); ?></span>
  36.  
  37. <?php endif; ?></h4>
  38.  
  39. <?php
  40. $tag_description = tag_description();
  41. if ( ! empty( $tag_description ) )
  42. echo apply_filters( 'tag_archive_meta', '<div class="tag-archive-meta">' . $tag_description . '</div>' );
  43. ?>
  44.  
  45. </div> <!-- /section-inner -->
  46.  
  47. </div> <!-- /page-title -->
  48.  
  49. <div class="clear"></div>
  50.  
  51. <?php if ( have_posts() ) : ?>
  52.  
  53. <?php rewind_posts(); ?>
  54.  
  55. <?php while ( have_posts() ) : the_post(); ?>
  56.  
  57. <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
  58.  
  59. <?php get_template_part( 'content', get_post_format() ); ?>
  60.  
  61. </div> <!-- /post -->
  62.  
  63. <?php endwhile; ?>
  64.  
  65. </div> <!-- /posts -->
  66.  
  67. <?php if ( $wp_query->max_num_pages > 1 ) : ?>
  68.  
  69. <div class="archive-nav">
  70.  
  71. <?php echo get_next_posts_link( '&laquo; ' . __('Older posts', 'radcliffe')); ?>
  72.  
  73. <?php echo get_previous_posts_link( __('Newer posts', 'radcliffe') . ' &raquo;'); ?>
  74.  
  75. <div class="clear"></div>
  76.  
  77. </div> <!-- /post-nav archive-nav -->
  78.  
  79. <?php endif; ?>
  80.  
  81. <?php endif; ?>
  82.  
  83. </div> <!-- /content -->
  84.  
  85. <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement