Posted By

themolitor on 06/17/10


Tagged


Versions (?)

Who likes this?

4 people have marked this snippet as a favorite

d55beck
artificialid
maxvee8
athanassiadis


WordPress: Custom Loop w/ Pagination


 / Published in: PHP
 

  1. <?php
  2. $temp = $wp_query;
  3. $wp_query= null;
  4. $wp_query = new WP_Query();
  5. $wp_query->query('category_name=blog&showposts=1'.'&paged='.$paged);
  6. while ($wp_query->have_posts()) :
  7. $wp_query->the_post();
  8. ?>
  9.  
  10. <!--THIS IS THE POST CONTENT-->
  11.  
  12. <?php
  13. endwhile;
  14. $wp_query = null;
  15. $wp_query = $temp;
  16. ?>

Report this snippet  

You need to login to post a comment.