Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $terms = get_the_terms( $post->ID, 'reources-category' );?>
- <?php $arg = array(
- 'post_type' => 'resources-directory',
- 'order' => 'ASC',
- 'orderby' => 'title',
- 'posts_per_page' => -1,
- 'tax_query' => array(
- 'relation' => 'AND',
- array(
- 'taxonomy' => 'reources-category',
- 'field' => 'slug',
- 'terms' => $terms
- ))
- );
- $the_query = new WP_Query( $arg );
- if ( $the_query->have_posts() ) : ?>
- <?php while ( $the_query->have_posts() ) : $the_query->the_post();
- $do_not_duplicate = $post->ID; ?><!-- BEGIN of Post -->
- <h3><?php the_title(); ?></h3>
- <?php the_content(); ?>
- <?php endwhile; ?><!-- END of Post -->
- <?php endif; wp_reset_query(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement