display opening events

Home Forums Calendar Products Events Calendar PRO display opening events

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #21139
    Weijing
    Member

    Hi,
    Is there a way to display opening events in the future instead of listing ongoing events?
    We have a lot of ongoing events which really make the upcoming events list looks dated because it starts with events opened months ago.
    Thanks

    #21167
    Weijing
    Member

    This is the code I’m using right now:
    global $post;
    $start_date= date(‘j M Y’,);
    $end_date = date(‘j M Y’, strtotime(‘7 days’));

    $get_posts = tribe_get_events(array(‘start_date’=>$current_date,’end_date’=>$end_date,’posts_per_page’=>10) );

    foreach($get_posts as $post) { setup_postdata($post);

    /*post*/
    } //endforeach
    wp_reset_query();

    But the returned list looks exactly the same as the default template.
    can anyone help?

    #21177
    Joyce Grace
    Member

    Hi Weijing,

    Can you link to your site for us? Also, by “opening” events, do you mean the same thing as “upcoming” events?

    Are you trying to get upcoming events to appear before recurring (i.e. ongoing) events in the events list? Or by “ongoing” events do you mean something different than recurring events?

    Thanks!

    #21253
    Weijing
    Member

    by “opening” i mean events of which the start date is today.
    ongoing events is what the default upcoming events is.
    http://www.nihao-chicago.com/events/
    this is our site.(it’s in chinese) as you can see, the first event in the list starts on may 4th and ends on sep 23. it looks as if the list is dated.

    #21304
    Joyce Grace
    Member

    Hello Weijing,

    I see what you mean, but I’m still not clear what you are trying to do. Are you trying to get ongoing events to display beneath events that haven’t started yet? Or are you trying to get events that start today to go at the top of your list?

    Both of those scenarios are really a level of customization we can’t offer on free support. You would need to pay a developer to do that type of work for you.

    However, a suggestion that might work for you is to try to categorize your events, using the event categories. Then you can have a menu in your web site navigation that leads to specific event categories, which in your case would be ordered by “upcoming,” “ongoing” and “happening today”. Our sidebar widget can also do this for you. You would need to create custom menu links using WordPress menus, and link to that specific category archive, so users can filter accordingly.

    I hope this is somewhat of a solution for you, with the functionality that exists with the plugin already!

    #21366
    Weijing
    Member

    Thanks Joyce
    I solved it using wp_query.

    #21582
    Rob
    Member

    Glad to hear you got this figured out, Weijing. If you need anything else down the road or if we can help in any other way please let us know.

Viewing 7 posts - 1 through 7 (of 7 total)
  • The topic ‘display opening events’ is closed to new replies.