Advertisement
Guest User

tag.php

a guest
Aug 14th, 2013
170
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 2.87 KB | None | 0 0
  1. <?php get_header(); ?> 
  2.  
  3. <?php if (have_posts()) : ?>
  4.  
  5. <?php $post = $posts[0]; // Hack. Set $post so that the_date() works. ?>
  6.  
  7. <?php /* If this is a category archive */ if (is_category()) { ?>
  8.  
  9.     <h2><?php _e('Archive for the','text_domain'); ?> &#8216; <?php single_cat_title(); ?> &#8217; <?php _e('Category','text_domain'); ?></h2>
  10.  
  11. <?php /* If this is a tag archive */ } elseif( is_tag()) { ?>
  12.  
  13.     <h2><?php _e('Showing pages tagged', 'text_domain'); ?> &#8216; <?php single_tag_title(); ?> &#8217;</h2>
  14.  
  15. <?php /* If this is a daily archive */ } elseif (is_day()) { ?>
  16.  
  17.     <h2><?php _e('Archive for','text_domain'); ?> <?php the_time('F jS, Y'); ?></h2>
  18.  
  19. <?php /* If this is a monthly archive */ } elseif (is_month()) { ?>
  20.  
  21.     <h2><?php _e('Archive for','text_domain'); ?> <?php the_time('F, Y'); ?></h2>
  22.  
  23. <?php /* If this is a yearly archive */ } elseif (is_year()) { ?>
  24.  
  25.     <h2><?php _e('Archive for','text_domain'); ?> <?php the_time('Y'); ?></h2>
  26.  
  27. <?php /* If this is an author archive */ } elseif (is_author()) { ?>
  28.  
  29.     <h2><?php _e('Author Archive','text_domain'); ?> </h2>
  30.  
  31. <?php /* If this is a paged archive */ } elseif (isset($_GET['paged']) && !empty($_GET['paged'])) { ?>
  32.  
  33.     <h2><?php _e('Blog Archives','text_domain'); ?> </h2>
  34.  
  35. <?php } ?>
  36.  
  37. <?php while (have_posts()) : the_post(); ?>
  38.  
  39.     <div <?php post_class() ?>>
  40.  
  41.         <div id="section-inner">
  42.  
  43.             <div id="section-one-sub-heading" style="margin-bottom:0px;">
  44.  
  45.                 <a href="<?php the_permalink(); ?> "><?php the_title(); ?></a>
  46.  
  47.             </div><!--section-one heading-->
  48.  
  49.      <div id="section-one-content">
  50.  
  51.         <?php //include (TEMPLATEPATH . '/inc/meta.php' ); ?>  
  52.         <div class="meta"></div>
  53.  
  54.         <div class="entry">
  55.  
  56.            <?php if ( has_post_thumbnail() ) { ?>
  57.  
  58.                 <div class="thumb">
  59.  
  60.                     <?php the_post_thumbnail(); ?>
  61.  
  62.                 </div>
  63.  
  64.             <?php } ?>         
  65.  
  66.             <?php
  67.  
  68.                 global $more;    // Declare global $more (before the loop).
  69.  
  70.                 $more = 0;       // Set (inside the loop) to display content above the more tag.
  71.  
  72.                 the_content(__(''));
  73.  
  74.             ?>
  75.  
  76.             <div class="more-link">
  77.  
  78.                             <a href="<?php the_permalink(); ?>" style="margin-top:10px;">mere <span class="arrow"><img src="<?php bloginfo('template_directory'); ?>/images/arrow.png" width="12" height="11" /></span></a>
  79.  
  80.             </div><!--more link-->
  81.  
  82.             <?php wp_link_pages(array('before' => 'Pages: ', 'next_or_number' => 'number')); ?>
  83.  
  84.             <div class="clear"></div>
  85.  
  86.         </div>
  87.  
  88.    </div>
  89.  
  90.      </div>
  91.  
  92.     </div>
  93.  
  94. <?php endwhile; ?>
  95.  
  96. <?php if (function_exists("pagination")) {
  97.  
  98.     pagination($additional_loop->max_num_pages);
  99.  
  100. } ?>           
  101.  
  102. <?php else : ?>
  103.  
  104.     <h2><?php _e('Nothing Found','text_domain'); ?></h2>
  105.  
  106. <?php endif; ?>
  107.  
  108. <?php get_sidebar(); ?>
  109.  
  110. <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement