SHARE
TWEET

New code - broken

a guest Nov 3rd, 2012 50 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <div id="container" class="clearfix isotope">
  2.  
  3. <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
  4.  
  5.        
  6.                 <?php $categories = get_the_category();
  7.                
  8.                         if($categories){ foreach($categories as $category) {
  9.                        
  10.                                 if($category->term_id == 3 ){ ?>
  11.                                        
  12.                                         This is the brand category - display this
  13.                                
  14.                                 <?php } ?>
  15.                
  16.                 <?php } } ?>
  17.                
  18. <?php endwhile; else: ?>
  19. <p><?php _e('Sorry, no posts matched your criteria.'); ?></p>
  20. <?php endif; ?>
  21. </div> <!-- /container -->
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top