Event List Sort by Month Header

Home Forums Calendar Products Events Calendar PRO Event List Sort by Month Header

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #11637
    Terrance
    Member

    Hi,
    In event list view, each of the event has their own event start date, which is good.

    How can I get only the ‘Month’ for all the events that fall within that month instead of having the individual date for each event.

    Something like this:

    Jan
    – Event 1
    – Event 2
    – Event 3
    Feb
    – Event 1
    – Event 2
    Mar
    – Event 1

    Thanks in advance.

    #11661
    Rob
    Member

    Thanks for the note, Terrance. That should be doable with a little hackery. Let me get our dev Jonah to chime in with his suggestions.

    #11700
    Terrance
    Member

    Cool, looking forward to it.

    #11836
    Rob
    Member

    Hey Terrance. I talked this over with Jonah. Looks like this is a rather complex task to do in WordPress alone, let alone with events. We are going to put together an FAQ/tutorial on this but it’s going to take some time to do – we’re aiming to get that published this week. Just wanted to give you a heads up since providing one-off hackery in this thread probably won’t be possible given the depth of work here. Apologies about that.

    #11878
    Terrance
    Member

    No problem. Thanks for getting back.

    Sure, I will look forward to the FAQ/tutorial. Let me know once it’s up. Thank you!

    #12044
    Sean
    Member

    I achieved what your looking for with relative ease, thought I would post what I did since I read this thread first looking for a solution.

    At the start of the loop after while statement in list.php I added:

    <?php if($events_list_month == $events_list_current_month) { } else { echo '’ .$events_list_current_month. ”; }

    ?>

    at at the end of the loop before the endwhile; I added:

    I’ve not tested it fully, but it appears to be working on my installation.

    #12045
    Sean
    Member

    That didn’t work, trying again:

    before loop:

    $events_list_current_month_date_format = ‘F’;
    $events_list_current_month = tribe_get_start_date( null, false, $events_list_current_month_date_format );

    if($events_list_month == $events_list_current_month) { } else { echo ” .$events_list_current_month. ”; }

    After loop:

    $events_list_month = $events_list_current_month;

    In PHP tags obviously.

    #12046
    Sean
    Member

    Still didn’t paste fully, oh well I tried.

    #12047
    Sean
    Member

    One last go

    start of loop

    <?php if($events_list_month == $events_list_current_month) { } else { echo '' .$events_list_current_month. ''; } ?>

    end of loop

    #12053
    Rob
    Member

    Hey Sean: thanks for this. We’re working to fix the forum so code pastes work fine here; in the interim, feel free to use pastie.org or something similar. Apologies for the inconvenience there.

    #12402
    Terrance
    Member

    Any update on this?

    #12435
    Rob
    Member

    We’re still putting together our tutorial on the subject but got derailed due to the bugs that came up in 2.0.2. If Sean can confirm anything on his end, that may give us a workaround in the interim. But this is still in the works on our end and will certainly be up on the site by the end of the month.

Viewing 12 posts - 1 through 12 (of 12 total)
  • The topic ‘Event List Sort by Month Header’ is closed to new replies.