Posted By

rliverman on 12/13/10


Tagged

post wordpress query querypost


Versions (?)

Who likes this?

1 person have marked this snippet as a favorite

qubestream


Basic Query Post


 / Published in: PHP
 

  1. <?php query_posts('posts_per_page=5'); ?>
  2.  
  3. <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
  4.  
  5. <?php endwhile; else: ?>
  6.  
  7. <?php endif; ?>
  8.  
  9. <?php wp_reset_query(); ?>

Report this snippet  

You need to login to post a comment.