WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top
$myquery['tax_query'] = array(
    'relation' => 'OR',
            'taxonomy' => 'brands',
            'terms' => array('ALL'),
            'field' => 'slug',
            'operator' => 'NOT_IN'
            'taxonomy' => 'media',
            'terms' => array('news', 'events'),
            'field' => 'slug',
            'operator' => 'NOT_IN'

if ( have_posts() ) : while ( have_posts() ) : the_post();?>
<php the-title(); ?>
<php endwhile; else: endif; ?>

share|improve this question
Yyyy... What exactly are you trying to accomplish? What do you mean by "post count in my taxonomy"? – Krzysiek Dróżdż Aug 6 '13 at 8:11

Just add $my_query['posts_per_page'] = 10; (or some other number) before query_posts call.

But I'm not sure if I understand you correctly.

share|improve this answer
Hi Krzysiek Dróżdż, thank you for your replay. it's not working, i updated the question.please check – Shihab Malayil Aug 6 '13 at 8:37
What is not working? How did you add it? As I can see, you don't know PHP very well - am I correct? – Krzysiek Dróżdż Aug 6 '13 at 10:39

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.