Home › Forums › Other › how to get custom posts for custom taxonomy ? › Reply To: how to get custom posts for custom taxonomy ?
October 1, 2013 at 3:22 am
#151782
amis
Participant
thx Energ
i have been used this but not work with me
<?php
$args = array(
'post_type' => 'videos',
'tax_query' => array(
'relation' => 'AND',
),
array(
'taxonomy' => 'type',
'field' => 'slug',
'terms' => array( $term->slug )
)
);
$query = new WP_Query( $args );
?>
<?php if(have_posts()) : ?>
<?php while(have_posts()) : the_post(); ?>
i will show you what i want defiently
i want when go to this link get what in it
http://localhost/wp/?type=comedy (get comedy only )
http://localhost/wp/?type=action (get action only)