Skip to content

Instantly share code, notes, and snippets.

@kalbers
Created April 5, 2012 17:43
Show Gist options
  • Save kalbers/2312786 to your computer and use it in GitHub Desktop.
Save kalbers/2312786 to your computer and use it in GitHub Desktop.
<?php {
$temp = $wp_query; // assign orginal query to temp variable for later use
global $wp_query;
global $post;
} ?>
<?php $paged = (get_query_var('paged')) ? get_query_var('paged') : 1; ?>
<?php $args = array( 'cat' => '-592, -614', 'post_status' => 'publish', 'paged' => $paged); ?>
<?php $wp_query = new WP_Query($args); ?>
<?php while ( $wp_query->have_posts() ) : $wp_query->the_post(); ?>
<?php get_template_part( 'content-results'); ?>
<?php endwhile; ?>
<?php wp_pagenavi(); // Use PageNavi ?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment