Skip to content

Instantly share code, notes, and snippets.

@georgestephanis
Forked from nikibrown/gist:3164909
Created July 23, 2012 17:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save georgestephanis/3164991 to your computer and use it in GitHub Desktop.
Save georgestephanis/3164991 to your computer and use it in GitHub Desktop.
<?php $tombstones = new WP_Query('category_name=tombstones&posts_per_page=-1&order=ASC'); ?>
<?php $counter = 0; ?>
<div class="slide">
<?php if ( $tombstones->have_posts() ) : while ( $tombstones->have_posts() ) : ?>
<?php if ( $counter && ( $counter % 3 == 0 ) ) echo "</div><!-- /slide -->\r\n\r\n<div class='slide'>"; ?>
<?php $tombstones->the_post(); $counter++; ?>
<?php the_content(); ?>
<?php endwhile; endif;?>
</div><!-- /slide -->
</div><!-- end slideshow -->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment