Advertisement
Guest User

archive.php

a guest
Aug 7th, 2012
92
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.75 KB | None | 0 0
  1. <?php get_header(); ?>
  2.  
  3.           <div id="pageHead">
  4.                <?php global $post; if(is_archive() && have_posts()) :
  5.  
  6.                     if (is_category()) : ?>
  7.                          <h1><?php single_cat_title(); ?></h1>                   
  8.                          <?php if(strlen(category_description()) > 0) echo category_description(); ?>
  9.                     <?php elseif( is_tag() ) : ?>
  10.                          <h1><?php single_tag_title(); ?></h1>
  11.                     <?php elseif (is_day()) : ?>
  12.                          <h1>Archive <?php the_time('M j, Y'); ?></h1>
  13.                     <?php elseif (is_month()) : ?>
  14.                          <h1>Archive <?php the_time('F Y'); ?></h1>
  15.                     <?php elseif (is_year()) : ?>
  16.                          <h1>Archive <?php the_time('Y'); ?></h1>
  17.                     <?php elseif (isset($_GET['paged']) && !empty($_GET['paged'])) : ?>
  18.                          <h1>Archive</h1>
  19.                     <?php endif; ?>
  20.  
  21.                <?php endif; ?>
  22.           </div>
  23.          
  24.                               
  25.           <div id="content" class="threeFourth clearfix">              
  26.                <?php while (have_posts()) : the_post(); ?>                  
  27.                     <div <?php post_class(); ?>>                        
  28.                          <div class="inside">                                                                          
  29.                               <h1><a href="<?php the_permalink() ?>" rel="bookmark" ><?php the_title(); ?></a></h1>
  30.                               <div class="meta clearfix">
  31.                                    <?php $post_show_author = of_get_option('ttrust_post_show_author'); ?>
  32.                                    <?php $post_show_date = of_get_option('ttrust_post_show_date'); ?>
  33.                                    <?php $post_show_category = of_get_option('ttrust_post_show_category'); ?>
  34.                                    <?php $post_show_comments = of_get_option('ttrust_post_show_comments'); ?>
  35.                                                  
  36.                                    <?php if($post_show_author || $post_show_date || $post_show_category){ _e('Posted ', 'themetrust'); } ?>                        
  37.                                    <?php if($post_show_author) { _e('by ', 'themetrust'); the_author_posts_link(); }?>
  38.                                    <?php if($post_show_date) { _e('on', 'themetrust'); ?> <?php the_time( 'M j, Y' ); } ?>
  39.                                    <?php if($post_show_category) { _e('in', 'themetrust'); ?> <?php the_category(', '); } ?>
  40.                                    <?php if(($post_show_author || $post_show_date || $post_show_category) && $post_show_comments){ echo " | "; } ?>
  41.                                   
  42.                                    <?php if($post_show_comments) : ?>
  43.                                         <a href="<?php comments_link(); ?>"><?php comments_number(__('No Comments', 'themetrust'), __('One Comment', 'themetrust'), __('% Comments', 'themetrust')); ?></a>
  44.                                    <?php endif; ?>
  45.                               </div>                             
  46.                              
  47.                               <?php if(has_post_thumbnail()) : ?>
  48.                                    <?php if(of_get_option('ttrust_post_featured_img_size')=="large") : ?>                                                      
  49.                                        <a href="<?php the_permalink() ?>" rel="bookmark" ><?php the_post_thumbnail('ttrust_post_thumb_big', array('class' => 'postThumb', 'alt' => ''.get_the_title().'', 'title' => ''.get_the_title().'')); ?></a>                  
  50.                                    <?php else: ?>
  51.                                         <a href="<?php the_permalink() ?>" rel="bookmark" ><?php the_post_thumbnail('ttrust_post_thumb_small', array('class' => 'postThumb alignleft', 'alt' => ''.get_the_title().'', 'title' => ''.get_the_title().'')); ?></a>
  52.                                    <?php endif; ?>
  53.                               <?php endif; ?>                                                                          
  54.                              
  55.                               <?php the_excerpt(); ?>
  56.                               <?php more_link(); ?>         
  57.                          </div>                                                                                                   
  58.                    </div>                   
  59.               
  60.                <?php endwhile; ?>
  61.               
  62.                <?php include( TEMPLATEPATH . '/includes/pagination.php'); ?>
  63.                                  
  64.           </div>         
  65.           <?php get_sidebar(); ?>                   
  66.     
  67.          
  68. <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement