Advertisement
Nessdufrat

Category template

Sep 29th, 2012
94
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.00 KB | None | 0 0
  1. <?php
  2. /**
  3.  * The template for displaying Category Archive pages.
  4.  *
  5.  * @package WordPress
  6.  * @subpackage Twenty_Ten
  7.  * @since Twenty Ten 1.0
  8.  */
  9.  
  10. get_header(); ?>
  11.  
  12.         <div id="container">
  13.             <div id="content" role="main">
  14.  
  15.     <h1 class="page-title <?php
  16.                 if (is_category_tree(3)):
  17.                     echo 'edition';
  18.                 if (is_category_tree(4)) :
  19.                     echo 'autopublication';
  20.                 ?>">
  21.  
  22.                 <? echo single_cat_title( '', false ) ; ?></h1>
  23.  
  24.                 <?php
  25.                     $category_description = category_description();
  26.                     if ( ! empty( $category_description ) )
  27.                         echo '<div class="archive-meta">' . $category_description . '</div>';
  28.  
  29.                 /* Run the loop for the category page to output the posts.
  30.                  * If you want to overload this in a child theme then include a file
  31.                  * called loop-category.php and that will be used instead.
  32.                  */
  33.                 get_template_part( 'loop', 'category' );
  34.                 ?>
  35.  
  36.             </div><!-- #content -->
  37.         </div><!-- #container -->
  38.  
  39. <?php get_sidebar(); ?>
  40. <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement