Ver Mensaje Individual
  #14 (permalink)  
Antiguo 19/01/2012, 08:59
RGT
Usuario no validado
 
Fecha de Ingreso: noviembre-2008
Mensajes: 505
Antigüedad: 15 años, 5 meses
Puntos: 5
Respuesta: Codigo para mostrar el primer post

Código PHP:
<?php $count 1// Seteamos count a 1 para la primer entrada ?>
 
<?php while (have_posts()) : the_post(); ?>

 <div id="post-<?php the_ID(); ?><?php post_class(); ?>

        <?php if ((function_exists('has_post_thumbnail')) && (has_post_thumbnail())) : ?>
        <div class="image"><a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('medium'); ?></a></div>        
        <?php endif; ?>
        <div class="snippet">
            <h2 class="title"><a href="<?php the_permalink(); ?>" title="<?php the_title() ?>" rel="bookmark"><?php the_title(); ?></a></h2>                    
            <p class="meta"><?php the_time('F j, Y'); ?></p>
            <div class="excerpt"><?php the_excerpt(); ?></div>            
        </div>
 
<?php } else { // el resto de las entradas se mostraran como pongamos ahora ?>
 
        <?php if ((function_exists('has_post_thumbnail')) && (has_post_thumbnail())) : ?>
        <div class="image"><a href="<?php the_permalink(); ?>"><?php the_post_thumbnail('thumbnail'); ?></a></div>        
        <?php endif; ?>
        <div class="snippet">
            <h2 class="title"><a href="<?php the_permalink(); ?>" title="<?php the_title() ?>" rel="bookmark"><?php the_title(); ?></a></h2>                    
            <p class="meta"><?php the_time('F j, Y'); ?></p>
            <div class="excerpt"><?php the_excerpt(); ?></div>            
        </div>

<?php $count++; // Final de la funcion ?>


        <!--Aqui el codigo para mostrar los elementos comunes a todas las entradas-->
Asi tengo el codigo!.