• Resolved polyfade

    (@polyfade)


    It’s possible to filter events by Organizer ID, but how is it done using Organizer slug?

    Example that works with ID:

    
    <?php
    $args = array(
    'post_type' => array(TribeEvents::POSTTYPE), 
    'posts_per_page' => -1,
    'order' => 'ASC',
    'organizer' => '73' // ID used, need slug instead
    
    );
    
    $events = new WP_Query( $args );
    
    if($events->have_posts()) : while ( $events->have_posts() ) : $events->the_post();
    ?>
    …
    
Viewing 1 replies (of 1 total)
  • Barry

    (@barryhughes-1)

    Hi @polyfade,

    One approach would be to use an initial query to convert the slugs into IDs first of all, before passing them to your next query.

    However, simply because we really need to prioritize support for our premium users, I’m afraid to say custom dev tasks like this one aren’t generally something we’re positioned to provide much help with here in the wordpress.org forums.

    I do wish you luck with your project, though 🙂

Viewing 1 replies (of 1 total)
  • The topic ‘Filter events by Organizer slug NOT ID’ is closed to new replies.