2-column post page layout
-
I’m trying to make the sketchbook section of my site display the posts in two columns. it’s working except not quite right. i want it to display as a grid, not have large amounts of space beneath some images, i want it to be the same amount of space. i realize that the problem is that my images/posts are different sizes but is there anything i can do so that i can lay them out in this way, without having weird gaps in spacing?
if that didn’t make total sense, looking at it live will probably clear it up:
https://ankatankdesign.com/makes/these/sketchbookand this is my code:
<div id="container"> <?php get_sidebar() ?> <div class="prev-btn"><?php previous_posts_link( __( '<img src="https://ankatankdesign.com/images/btns/next-prev/prev_btn_normal.gif" width="51" height="95" onmouseover="this.src=\'https://ankatankdesign.com/images/btns/next-prev/prev_btn_ro2.gif\';" onmouseout="this.src=\'https://ankatankdesign.com/images/btns/next-prev/prev_btn_normal.gif\';">', TRUE) ) ?> </div> <div id="content" style="width:825px;"> <?php while ( have_posts() ) : the_post() ?> <div id="post-<?php the_ID() ?>" class="<?php sandbox_post_class() ?>" style="float:left; top:auto;"> <div class="entry-content"> <div class="thepost-sketch"> <?php the_content() ?> <div style="float:right; margin-right:15px;"> <?php edit_post_link( ); ?> </div> </div><!--eo thepost --> </div><!--eo entry content --> <br style='clear:both;' /> </div><!-- #post --> <?php endwhile; ?> </div><!-- #content --> </div><!-- #container --> </div> <div class="next-btn"><?php next_posts_link( __( '<img src="https://ankatankdesign.com/images/btns/next-prev/next_btn_normal.gif" width="51" height="95" onmouseover="this.src=\'https://ankatankdesign.com/images/btns/next-prev/next_btn_ro2.gif\';" onmouseout="this.src=\'https://ankatankdesign.com/images/btns/next-prev/next_btn_normal.gif\';">', TRUE) ) ?> </div> <br style='clear:both;' />
so to reiterate, basically, i want to be able to have different sized posts (dependent on the size of image in them), and lay them out in two columns, with the same amount of gutter space between these different sized items/posts. the width will be constant, the height will not be.
if anyone can help i would really appreciate it!
thanks!
- The topic ‘2-column post page layout’ is closed to new replies.