Exclude taxonomy by term not work with pagination link
-
Exclude Custom taxonomy by term/category not work with pagination link
$args['tax_query'] = array( array( 'taxonomy' => 'category', 'terms' => array('cat', 'dog'), 'field' => 'slug', 'operator' => 'NOT IN', ), ); query_posts($args);
Full code:
<?php $args['tax_query'] = array( array( 'taxonomy' => 'category', 'terms' => array('cat', 'dog'), 'field' => 'slug', 'operator' => 'NOT IN', ), ); query_posts($args); ?> <?php if ( have_posts() ) : ?> <?php /* Start the Loop */ ?> <?php while ( have_posts() ) : the_post(); ?> <?php get_template_part( 'content', get_post_format() ); ?> <?php endwhile; ?> <?php link_pagination( ); ?> <?php else : ?>
Please help me. Tanks you for answer.
Viewing 8 replies - 1 through 8 (of 8 total)
Viewing 8 replies - 1 through 8 (of 8 total)
- The topic ‘Exclude taxonomy by term not work with pagination link’ is closed to new replies.