Title: custom query_posts
Last modified: August 20, 2016

---

# custom query_posts

 *  Resolved [mamulea](https://wordpress.org/support/users/mamulea/)
 * (@mamulea)
 * [13 years, 8 months ago](https://wordpress.org/support/topic/custom-query_posts-1/)
 * Hi. I would like to get a custom query_posts, based either on a category OR a
   specific tag. The query content would be something like _cat=xx **OR** tag=”slug”_,
   but I only find docs based on cummulative conditions (&). Is there any way to
   achieve this?

Viewing 2 replies - 1 through 2 (of 2 total)

 *  [vtxyzzy](https://wordpress.org/support/users/vtxyzzy/)
 * (@vtxyzzy)
 * [13 years, 8 months ago](https://wordpress.org/support/topic/custom-query_posts-1/#post-3024022)
 * See the examples under ‘Multiple Taxonomy Handling’ in this Codex article:
    [http://codex.wordpress.org/Class_Reference/WP_Query#Taxonomy_Parameters](http://codex.wordpress.org/Class_Reference/WP_Query#Taxonomy_Parameters)
 * The ‘relation’ => ‘OR’ example is the relevant one.
 *  Thread Starter [mamulea](https://wordpress.org/support/users/mamulea/)
 * (@mamulea)
 * [13 years, 8 months ago](https://wordpress.org/support/topic/custom-query_posts-1/#post-3024060)
 * 10x a lot, that was exactly what i needed.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘custom query_posts’ is closed to new replies.

## Tags

 * [query_posts](https://wordpress.org/support/topic-tag/query_posts/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 2 replies
 * 2 participants
 * Last reply from: [mamulea](https://wordpress.org/support/users/mamulea/)
 * Last activity: [13 years, 8 months ago](https://wordpress.org/support/topic/custom-query_posts-1/#post-3024060)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
