Title: query multiple categories
Last modified: August 22, 2016

---

# query multiple categories

 *  Resolved [thomastrethan](https://wordpress.org/support/users/thomastrethan/)
 * (@thomastrethan)
 * [11 years, 5 months ago](https://wordpress.org/support/topic/query-multiple-categories/)
 * it would be great to query mutliple categories by slug. this way it’ll be possible
   to have a grouped display of multiple categories.
 * in eme_categories.php the function eme_get_category_ids() already returns an 
   array of category ids, but can only handle a single slug as parameter. I’d suggest
   to allow multiple slugs to be passed and use SQL in-condition. in order to use
   multiple slug with url-parameters (eme_event_cat), I’d suggest to use a + to 
   join multiple categories.
 * my current (simple and working) hack in eme_categories.php in function eme_get_category_ids():
   `-
   $conditions = " category_slug = '$cat_slug'"; + $cat_slugs = implode("','", explode("
   +", $cat_slug)); + $conditions = " category_slug IN ('$cat_slugs')";
 * this way it is possible to call an url like:
    [http://www.domain.com/events/cat/slug1+slug2/](http://www.domain.com/events/cat/slug1+slug2/)
 * kind regards, Tom
 * [https://wordpress.org/plugins/events-made-easy/](https://wordpress.org/plugins/events-made-easy/)

Viewing 1 replies (of 1 total)

 *  Plugin Author [Franky](https://wordpress.org/support/users/liedekef/)
 * (@liedekef)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/query-multiple-categories/#post-5596086)
 * Would you mind posting this as a feature request at [http://www.e-dynamics.be/wordpress](http://www.e-dynamics.be/wordpress)?

Viewing 1 replies (of 1 total)

The topic ‘query multiple categories’ is closed to new replies.

 * ![](https://ps.w.org/events-made-easy/assets/icon-256x256.png?rev=1856035)
 * [Events Made Easy](https://wordpress.org/plugins/events-made-easy/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/events-made-easy/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/events-made-easy/)
 * [Active Topics](https://wordpress.org/support/plugin/events-made-easy/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/events-made-easy/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/events-made-easy/reviews/)

## Tags

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

 * 1 reply
 * 2 participants
 * Last reply from: [Franky](https://wordpress.org/support/users/liedekef/)
 * Last activity: [11 years, 4 months ago](https://wordpress.org/support/topic/query-multiple-categories/#post-5596086)
 * Status: resolved