• 1.
        	<?php if($post->post_content != "") { ?>
  • 2.
    		<hr class="break-5 clearfix" />
  • 3.
    		<?php the_content(); ?>
  • 4.
            <hr class="break-portfolio clearfix" />
  • 5.
            <?php } else { echo '<hr class="break-10" />'; } ?>
  • 6.
            
  • 7.
    		<?php
  • 8.
    		//show portfolio filter unless disabled
  • 9.
       		if(empty($data['disable_portfolio_filter'])) {
  • 10.
    		//get portfolio categories
  • 11.
    		$cats = get_terms('portfolio_cats');
  • 12.
    		//show filter if categories exist
  • 13.
    		if($cats) { ?>
  • 14.
            <ul class="portfolio-main filter clearfix">
  • 15.
    		    <li class="filter-by-text"><?php _e('Filter by'); ?></li>
  • 16.
                <li class="cat-item"><a href="#all" rel="all" class="active"><?php _e('All', 'kraken'); ?></a></li>
  • 17.
                <?php
  • 18.
                foreach ($cats as $cat ) : ?>
  • 19.
                <li class="cat-item"><a href="#<?php echo $cat->slug; ?>" rel="<?php echo $cat->slug; ?>"><?php echo $cat->name; ?></a></li>
  • 20.
                <?php endforeach; ?>
  • 21.
            </ul>
  • 22.
            <!-- .portfolio-main -->
  • 23.
            <?php } } ?>
<?php if($post->post_content != "") { ?> <hr class="break-5 clearfix" /> <?php the_content(); ?> <hr class="break-portfolio clearfix" /> <?php } else { echo '<hr class="break-10" />'; } ?> <?php //show portfolio filter unless disabled if(empty($data['disable_portfolio_filter'])) { //get portfolio categories $cats = get_terms('portfolio_cats'); //show filter if categories exist if($cats) { ?> <ul class="portfolio-main filter clearfix"> <li class="filter-by-text"><?php _e('Filter by'); ?></li> <li class="cat-item"><a href="#all" rel="all" class="active"><?php _e('All', 'kraken'); ?></a></li> <?php foreach ($cats as $cat ) : ?> <li class="cat-item"><a href="#<?php echo $cat->slug; ?>" rel="<?php echo $cat->slug; ?>"><?php echo $cat->name; ?></a></li> <?php endforeach; ?> </ul> <!-- .portfolio-main --> <?php } } ?>

Copy Code to Clipboard Raw

Sign-in or Create a Free Account.

Snippi uses Twitter or Facebook to register and create accounts. Registration will enable you to keep track of your snippets. We never spam your timeline or wall. Ever.

Sign-in with Facebook Sign-in with Twitter