Advertisement
BakerMan

tribe_get_events() with tax query

Oct 25th, 2012
271
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.36 KB | None | 0 0
  1. /**
  2.  * Retrieve all events between Nov 1 and Nov 30
  3.  * that relate to category my-slug
  4.  */
  5. $events = tribe_get_events(array(
  6.     'start_date' => '2012-11-01',
  7.     'end_date' => '2012-11-30',
  8.     'posts_per_page' => 20,
  9.     'eventDisplay' => 'all',
  10.     'tax_query' => array(array(
  11.         'taxonomy' => TribeEvents::TAXONOMY,
  12.         'field' => 'slug',
  13.         'terms' => 'my-slug'))
  14. ));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement