You should have a look at the arguments of WP_Query. The following arguments should be what you need. Note that tax_query
takes an array of arrays.
$args = array(
'post_type' => array( 'post', 'videos', 'music' ),
'tax_query' => array(
array(
'taxonomy' => 'content',
'field' => 'slug',
'terms' => 'indy',
'operator' => 'NOT IN'
)
)
);
$myquery = new WP_Query( $args );
while( $myquery->have_posts() ):
$myquery->the_post();
# do your stuff here
endwhile;
Related Posts:
- How do I append multiple taxonomies to the URL?
- How to get the parent’s taxonomy?
- Query posts by custom post type and custom taxonomy
- Conditional Query of Custom Post Type and custom taxonomy
- attach CPT data to a taxonomy
- How can i display a taxonomy? i have created a plugin and then a custom type. and a taxonomy , also i have register it
- Set a Default CPT taxonomy by taxonomy id
- Sort by Custom Post Type (Multiple Loop)
- Inserting two categories
- Custom Taxonomy as checkbox or dropdown
- Custom Taxonomy as Dropdown in admin
- Custom Taxonomy’s Label to change the text appearing in Appearance > Menu
- How to completely disable a taxonomy archive on the frontend?
- How to limit the number of terms (terms acts like categories)
- How can I list all the categories under a Custom Post Type (taxonomy)?
- How to show term-specific post list, without posts associated with child terms?
- Custom Post Type with Custom Title
- Query multiple taxonomy in Custom Post Type
- automatically create taxonomy with same name as post title
- Query post types with multiple keys
- Query for posts in 2 taxonomies
- Custom post type taxonomy template
- Is slug “type” reserved and can’t be used in taxonomy rewrite?
- Remove Taxonomy Slug when No Taxonomy is Assigned to Custom Post Type?
- Best practice for adding posts in bulk
- WP 3.1 getting tax_query to work in query_posts()
- Taxonomy Templates
- How to dynamically build a multiple taxonomy query loop within a post type’s single loop?
- Custom Taxonomy Creates Unwanted Integer Terms on Post Save
- Weird problem happening with custom taxonmy when creating/updating posts
- How can I move a custom taxonomy and its data from one post type to another?
- Query Multiple Taxominies Across Multiple Post type’s
- Custom Taxonomies not appearing in Admin
- Custom Post Type Taxonomy Filters
- How to use custom taxonomies to reference complex relationships?
- will post_id ever change? Can I safely use post_id for custom queries?
- Show a Category X’s custom post type on Category X archive page?
- Taxonomy custom post type URL
- How do I move/order posts with a tag to the end?
- Use same slug base for Custom Post Type posts, and multiple taxonomy terms
- Get related posts of child term of custom post type
- How do I display the taxonomy for a custom post type in an array
- How do I check if the user is on a taxonomy term parent, child or grandchild page?
- How to edit this code to get the categories in achieve page?
- WordPress Doesn’t Generate Taxonomy Archive
- Suggested Post and Taxonomy structure
- Custom post with more than one custom taxonomy
- Get the taxonomy of a post hierarchically
- How to get list of taxonomy slugs ordered parents>childs?
- Multiple tag cloud filtering
- Get url.com/post_type/taxonomy/term work!
- How to produce a sub-page-system in WordPress
- Different Category system needed for the Custom Post Type
- Custom Post Type Category Link
- Custom Post type category pages template and loop
- Custom post type, custom taxonomy, query posts only from taxonomy (children of)
- How can I create an automatic drop down menu with my tags?
- How to define a term for custom taxonomy
- List custom taxonomy as navigation – taxonomy pages with all it’s posts?
- Get taxonomy singular name instead of taxonomy slug inside $taxonomy query
- Query custom post types & Taxonomies and list them in a table on a page
- Display Custom Post Types Glossary
- Creating custom post type posts and associating them with a post from another custom post type
- How should I structure complex content hierarchies?
- Getting List of child terms from custom taxonomy parent
- Get terms for a specfic post from multiple taxonomies in custom post type
- Problems making shortcode with custom post types and taxonomy
- Custom Post taxonomy template
- How to display posttypes and taxonomy in standard posts, not in a separate label?
- Is it possible to have hierarchical taxonomy and hierarchical custom post types in one permalink?
- How to get post count of specific taxonomy that have store name & category
- Duplicate slug/permalink issue while adding same post name
- Custom post type archive page filters
- Filter taxonomy by CPT
- wp_set_object_terms creates taxonomies but does not add custom posts to it
- custom post type and user post count shortcode
- WP_Query for custom taxonomies showing posts from non-specified terms?
- Get all posts for custom taxonomy term
- Display custom tax in “while” loop
- CPT: multiple loops with different terms
- tax_query not working?
- I want to create an archive and single page for a custom taxonomy for a custom post type
- Taxonomy’s title
- Display all posts from single taxonomy term
- Connect 8 Taxonomies to One (Main) taxonomy. How to?
- Filter By Term Not Working – Custom Post Type
- WordPress query posts by custom post type not workng
- WP_Query for CPT with filter by another WP_Query
- Display 2nd category, only once, as sub-heading, in the loop
- Custom post type post taxonomies
- Get link for feed of specific post type AND taxonomy
- How to apply order on custom taxonomy and custom meta key on custom post type
- Custom posts and custom taxonomies for many products and categories?
- List custom taxonomy terms
- How do i get the taxonomy term name on the CPT archive page?
- Query multiple post of which one by taxonomy
- Display associated taxonomy child name on single CPT page
- Issue On Listing Woocommerce Parent Tag List
- How to add to taxonomies to a post type
- Filtering custom post types using category taxonomy