Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <div id="container" class="clearfix isotope">
- <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
- <?php $my_query = new WP_Query('cat=3');?>
- <div class="element category-heading no-img y8" data-sort-brand="BRAND">
- <img src="<?php bloginfo('template_url'); ?>/img/tp.png" />
- <span class="centered">
- <h2>Brand</h2>
- </span>
- </div>
- <?php while ($my_query->have_posts()) : $my_query->the_post();
- $do_not_duplicate = $post->ID; ?>
- <div class="element isotape-valueitem" data-sort-brand="BRAND:<?php the_time('YmdHi') ?>">
- <div class="details y7a">
- <a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>"><h2><?php the_title(); ?></h2></a>
- </div>
- <a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>">
- <?php // If a featured image is specified display it otherwise display default transparent image
- $url = get_template_directory_uri();
- if(has_post_thumbnail()) {
- the_post_thumbnail();
- } else {
- echo '<img src="' . $url . '/img/tp.png" />';
- }
- ?>
- </a>
- </div>
- <?php endwhile; ?>
- <?php $print_query = new WP_Query('cat=5');?>
- <div class="element category-heading no-img y8" data-sort-print="PRINT">
- <img src="<?php bloginfo('template_url'); ?>/img/tp.png" />
- <span class="centered">
- <h2>Print</h2>
- </span>
- </div>
- <?php while ($print_query->have_posts()) : $print_query->the_post();
- $do_not_duplicate = $post->ID; ?>
- <div class="element isotape-valueitem" data-sort-print="PRINT:<?php the_time('YmdHi') ?>">
- <div class="details y7a">
- <a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>"><h2><?php the_title(); ?></h2></a>
- </div>
- <a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>">
- <?php // If a featured image is specified display it otherwise display default transparent image
- $url = get_template_directory_uri();
- if(has_post_thumbnail()) {
- the_post_thumbnail();
- } else {
- echo '<img src="' . $url . '/img/tp.png" />';
- }
- ?>
- </a>
- </div>
- <?php endwhile; ?>
- <?php $digital_query = new WP_Query('cat=4');?>
- <div class="element category-heading no-img y8" data-sort-digital="DIGITAL">
- <img src="<?php bloginfo('template_url'); ?>/img/tp.png" />
- <span class="centered">
- <h2>Digital</h2>
- </span>
- </div>
- <?php while ($digital_query->have_posts()) : $digital_query->the_post();
- $do_not_duplicate = $post->ID; ?>
- <div class="element isotape-valueitem" data-sort-digital="DIGITAL:<?php the_time('YmdHi') ?>">
- <div class="details y7a">
- <a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>"><h2><?php the_title(); ?></h2></a>
- </div>
- <a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>">
- <?php // If a featured image is specified display it otherwise display default transparent image
- $url = get_template_directory_uri();
- if(has_post_thumbnail()) {
- the_post_thumbnail();
- } else {
- echo '<img src="' . $url . '/img/tp.png" />';
- }
- ?>
- </a>
- </div>
- <?php endwhile; ?>
- <?php $film_query = new WP_Query('cat=12');?>
- <div class="element category-heading no-img y8" data-sort-film="FILM">
- <img src="<?php bloginfo('template_url'); ?>/img/tp.png" />
- <span class="centered">
- <h2>Film</h2>
- </span>
- </div>
- <?php while ($film_query->have_posts()) : $film_query->the_post();
- $do_not_duplicate = $post->ID; ?>
- <div class="element isotape-valueitem" data-sort-film="FILM:<?php the_time('YmdHi') ?>">
- <div class="details y7a">
- <a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>"><h2><?php the_title(); ?></h2></a>
- </div>
- <a href="<?php the_permalink(); ?>" title="<?php the_title(); ?>">
- <?php // If a featured image is specified display it otherwise display default transparent image
- $url = get_template_directory_uri();
- if(has_post_thumbnail()) {
- the_post_thumbnail();
- } else {
- echo '<img src="' . $url . '/img/tp.png" />';
- }
- ?>
- </a>
- </div>
- <?php endwhile; ?>
- <?php endwhile; else: ?>
- <p><?php _e('Sorry, no posts matched your criteria.'); ?></p>
- <?php endif; ?>
- </div> <!-- /container -->
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement