Que tal amigos, ojala pudieran ayudarme, tengo un loop de 1 columna, pero quiero hacerlo en 2 columnas. Este es el código actual :
Código PHP:
<div id="rightcol">
<?php
// enter the IDs of which categories you want to display
$display_categories = array(7);
foreach ($display_categories as $category) { ?>
<div class="clearfloat">
<?php query_posts("showposts=4&cat=$category");
$wp_query->is_category = true;
$wp_query->is_archive = false;
$wp_query->is_home = true;
?>
<h3><a href="<?php echo get_category_link($category);?>">
<?php
// name of each category gets printed
single_cat_title(); ?>
</a></h3>
<?php while (have_posts()) : the_post(); ?>
<?php
// this grabs the image filename
$values = get_post_custom_values("leadimage");
// this checks to see if an image file exists
if (isset($values[0])) {
?>
<a href="<?php the_permalink() ?>" rel="bookmark" class="title">
<?php
// this is where title of the article gets printed
the_title(); ?>
</a>
<a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><img src="<?php $values = get_post_custom_values("leadimage"); echo $values[0]; ?>" alt="" /></a>
<?php } ?>
<?php
// this is where the excerpt of the Lead Story gets printed
the_excerpt() ; ?> <br>
<?php endwhile; ?>
</div>
<?php }?>
</div>