Advertisement
Guest User

Untitled

a guest
Jun 8th, 2012
56
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.17 KB | None | 0 0
  1. <?php get_header(); ?>
  2. </div><div id="gridContainer">
  3. <?php
  4. if (is_home()) {
  5. query_posts("cat=-94"."&posts_per_page=9");
  6. }
  7. ?>
  8. <?php
  9. $c = 1; //init counter
  10. $bpr = 3; //boxes per row
  11. if(have_posts()) :
  12. while(have_posts()) :
  13. the_post();
  14. ?>
  15. <div class="gridpost" id="post-<?php the_ID(); ?>">
  16. <a href="<?php the_permalink(); ?>"><div class="postImage" id="fade">
  17. <div class="postData"><div id="gridTitle"><?php the_title(); ?></div></div><?php the_post_thumbnail('grid-post-image'); ?></a>
  18. </div>
  19. <?php if($c%3 == 0){
  20. $c = 'last';
  21. }else{
  22. $c = '';
  23. }
  24. $c++;
  25. ?>
  26. </div>
  27.  
  28. <?php
  29. if($c == $bpr) :
  30. ?>
  31.  
  32. <div class="clr"></div>
  33.  
  34.  
  35. <?php
  36. $c = 0;
  37. endif;
  38. ?>
  39.  
  40. <?php
  41. $c++;
  42. endwhile;
  43. endif;
  44. ?>
  45.  
  46. <div class="clr"></div>
  47.  
  48. <div class="ohmbbpagenav">
  49. <div class="pagination">
  50. <?php
  51. global $wp_query;
  52. $big = 999999999; // need an unlikely integer
  53. echo paginate_links( array(
  54. 'base' => str_replace( $big, '%#%', esc_url( get_pagenum_link( $big ) ) ),
  55. 'format' => '?paged=%#%',
  56. 'current' => max( 1, get_query_var('paged') ),
  57. 'total' => $wp_query->max_num_pages
  58. ) );
  59. ?>
  60. </div>
  61. </div>
  62.  
  63. </div>
  64. <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement