Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- get_header();
- // Categories to be excluded from the main loop
- // get_category_id is a function i made in functions.php that takes a name as a parameter and returns that categories
- // id
- $cat1 = get_category_id("cat1");
- $cat2 = get_category_id("cat2");
- $cat3 = get_category_id("cat3");
- $categories = array($swiss, $supper, $thoughts);
- $args = array(
- 'category__not_in' => $categories
- );
- $the_query = new WP_Query($args);
- ?>
- <section class="main_content">
- <?php if ( $the_query->have_posts() ) : while ( $the_query->have_posts() ) : $the_query->the_post(); ?>
- <?php get_template_part('content', 'post'); ?>
- <?php endwhile; else: ?>
- No pages or posts available.
- <?php
- endif;
- ?>
- <div class="pagination_container">
- // borrowing the pagination plugin found on kriesi.at
- <?php kriesi_pagination(); ?>
- </div>
- </section>
- <?php
- wp_reset_postdata();
- get_sidebar();
- get_footer();
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement