Advertisement
Guest User

category page

a guest
Jan 14th, 2014
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.90 KB | None | 0 0
  1. <?
  2.     get_header();
  3.    
  4.      <div id="content">
  5.          <div id="news">
  6.              
  7.          
  8.     <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
  9.    
  10.         <? include 'php/get_category.php'; ?>
  11.            
  12.        
  13.              
  14.         <div class="post <? echo $cat; ?>">
  15.  
  16.             <span class="meta">
  17.                 <span class="cat"><? echo $cat_name; ?> <span class="date"><?php the_time(get_option('date_format')); ?></span> </span>
  18.                 </span>
  19.  
  20.             <span class="fill">
  21.                  <h2><a href="<?php the_permalink() ?>"><?php the_title(); ?></a></h2>
  22.                 <? if ( has_post_thumbnail() ) ?>
  23.                        <a href="<?php the_permalink() ?>">  <?  the_post_thumbnail('front-thumbs'); ?> </a>
  24.                        
  25.     <span class="article-text">
  26.         <a href="<?php the_permalink() ?>"> <?php the_excerpt(); ?> </a>
  27.                         </span>
  28.                            </span>
  29.  
  30.  </div><!-- end post -->
  31.        
  32.  
  33.                  
  34.             <?php endwhile; endif; wp_reset_query(); ?>
  35.  
  36.            
  37.             <?php /* Display navigation to next/previous pages when applicable  */ ?>
  38.                 <?php if (  $wp_query->max_num_pages > 1 ) : ?>
  39.                                 <div id="nav-below" class="navigation">
  40.                                     <div class="nav-previous"><?php next_posts_link( __( '<span class="meta-nav">&larr;</span> Vorige artikelen' ) ); ?></div>
  41.                                     <div class="nav-next"><?php previous_posts_link( __( 'Volgende artikelen <span class="meta-nav">&rarr;</span>' ) ); ?></div>
  42.                                 </div><!-- #nav-below -->
  43.                 <?php endif; wp_reset_query(); ?>
  44.        
  45.        
  46.  
  47.           </div><!-- #news -->
  48.          
  49.          
  50.           <? // sidebar-selection
  51.          
  52.           if ( is_category('3') || is_category('69') ) {
  53.              
  54.                 get_sidebar('description');
  55.          
  56.                            
  57.         }  elseif ( is_category('11') ) {
  58.          
  59.                 get_sidebar('interview'); //this is the sidebar with the code in question that won't work
  60.                
  61.                            
  62.         } else {
  63.            
  64.                get_sidebar('latest');
  65.       }
  66.      
  67.           ?>
  68.          
  69.          
  70.          
  71.         </div><!-- #content -->
  72.        
  73.  
  74.            
  75.    
  76.     <? get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement