← WordPress

Posts em duas "colunas"

Lida 5095 vezes

Offline

Pedro Lopes 
Beta tester
Mensagens 3568 Gostos 18
Feedback +6

Troféus totais: 32
Trófeus: (Ver todos)
Level 6 Windows User Super Combination Combination Topic Starter 10 Poll Votes Poll Voter Level 5 Level 4 Level 3

Esqueci-me de ver, agora vou jantar, mas vejo já, já! ;)
Offline

Pedro Lopes 
Beta tester
Mensagens 3568 Gostos 18
Feedback +6

Troféus totais: 32
Trófeus: (Ver todos)
Level 6 Windows User Super Combination Combination Topic Starter 10 Poll Votes Poll Voter Level 5 Level 4 Level 3

Vê se resolve.

Ficheiro /layouts/default.php

Código: [Seleccione]
<div class="box">

<?php

$the_query = new WP_Query('cat=-'$GLOBALS[ex_feat] . ',-' $GLOBALS[ex_vid] . '&showposts=' get_option('woo_other_entries') . '&orderby=post_date&order=desc');

$counter 0$counter2 0;

while ($the_query->have_posts()) : $the_query->the_post(); $do_not_duplicate $post->ID;
?>


<?php $counter++; $counter2++; ?>

<div class="post">

<?php if ( get_post_meta($post->ID'image'true) ) { ?> <!-- DISPLAYS THE IMAGE URL SPECIFIED IN THE CUSTOM FIELD -->

<img src="<?php echo bloginfo('template_url'); ?>/thumb.php?src=<?php echo get_post_meta($post->ID"image"$single true); ?>&amp;h=57&amp;w=100&amp;zc=1&amp;q=90" alt="" class="th" />

<?php } else { ?> <!-- DISPLAY THE DEFAULT IMAGE, IF CUSTOM FIELD HAS NOT BEEN COMPLETED -->

<img src="<?php bloginfo('template_directory'); ?>/images/no-img-thumb.jpg" alt="" class="th" />

<?php ?>

<h2><?php the_category(', '?></h2>
<h3><a title="Link Permanente para <?php the_title(); ?>" href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h3>
<p class="posted"><?php _e('Postado em',woothemes); ?> <?php the_time('d F Y'); ?></p>
<p><?php echo strip_tags(get_the_excerpt(), '<a><strong>'); ?> <span class="continue"><a title="<?php _e('Link Permanente para',woothemes); ?> <?php the_title(); ?>" href="<?php the_permalink() ?>"><?php _e('Continua a Ler',woothemes); ?></a></span></p>
<p class="comments"><?php comments_popup_link(__('Comentário (0)',woothemes), __('Comentário (1)',woothemes), __('Comentários (%)',woothemes)); ?></p>

</div><!--/post-->

<?php if ( !($counter2 == get_option('woo_other_entries')) && ($counter == 0) ) { echo '<div class="hl-full"></div>'?> <div style="clear:both;"></div> <?php ?>

<?php endwhile; ?>


<div class="fix" style="height:20px"></div>

<p class="ar hl3"><a href="<?php echo get_option('woo_archives'); ?>" class="more"><?php _e('VE MAIS NOS ARQUIVOS',woothemes); ?></a></p>


</div><!--/box-->
Offline

Rafix 
Membro
Mensagens 343 Gostos 1
Troféus totais: 21
Trófeus: (Ver todos)
Super Combination Combination Topic Starter Poll Voter Level 4 Level 3 Level 2 Level 1 100 Posts 50 Posts

Funcionou :D e mesmo sem a alteração no css...

Mas consegues deixar um espaço entre os posts?
Offline

Rafix 
Membro
Mensagens 343 Gostos 1
Troféus totais: 21
Trófeus: (Ver todos)
Super Combination Combination Topic Starter Poll Voter Level 4 Level 3 Level 2 Level 1 100 Posts 50 Posts

Pedro, com as mudanças que deste se eu aumentar o tamanho da thumb os posts ficam desorganizados lol

O mambley já está no "site teste" e vai ver se continua com modificações feitas no css sem mexer no php.

 :obrigado: na mesma ;)

se ele não conseguir digo alguma coisa neste topico
Offline

Pedro Lopes 
Beta tester
Mensagens 3568 Gostos 18
Feedback +6

Troféus totais: 32
Trófeus: (Ver todos)
Level 6 Windows User Super Combination Combination Topic Starter 10 Poll Votes Poll Voter Level 5 Level 4 Level 3

Isso é no css, mexe prai, eu não instalei o theme pa ver como ficava.