Grid layout (side by side) with different post classes?
-
Hi! I’m working on a theme where i’m using the code below to grid posts side by side, the problem is that i’m working with Twitter bootstrap and i’d like to give the first and last post on each row a “pull-left” or “pull-right” class.
Any ideas?
<?php query_posts('category_name=Menucard'); ?> <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?> <div class="span4 post move pull-left"> <?php //echo post here the_content(); ?> </div> <!-- close .post div --> <?php $counter++; if ($counter % 3 == 0) { echo '<div style="clear:both;"></div>'; } ?>
- The topic ‘Grid layout (side by side) with different post classes?’ is closed to new replies.