day and date delineator header in list view

Home Forums Calendar Products Events Calendar PRO day and date delineator header in list view

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #1294810
    Robert
    Participant

    I have many events on each day. In the list view, there is no clear break separating each day in the long list of events. I’d like to force my list view to have a new day and date header at the start of each day to clearly delineate the start of a new day in the long list of events. How is this possible?

    #1295999
    Victor
    Keymaster

    Hi Robert!

    Thanks for reaching out to us! 🙂

    Sure! That is posible by making a template customization. We have a great article on customizing our templates here > https://theeventscalendar.com/knowledgebase/themers-guide/

    Specifically, you should take a look at the ‘tribe_events_list_the_date_headers()’ funtion located at /wp-content/plugins/the-events-calendar/src/views/list/loop.php. This function outputs month and years separators in the list. If you make use of the ‘tribe_events_list_the_date_headers’ filter you can customize the output to also add day separators.

    I hope that helps and let me know if you have other questions.

    Best,
    Victor

    #1296857
    Robert
    Participant

    I wish this made some sense to me. Can you tell me what to copy and paste in the loop file to give me a day header separator in the list view?

    #1296964
    Victor
    Keymaster

    Hi Robert!

    I’m sorry I was not clear enough.

    First off, I do want to note that we are fairly limited in how much we can support custom development questions like this.

    That said, I’d be happy to at least point you in the right direction as best I can. We also have a list of freelancers who we would happily recommend for this level of help.

    I managed to come up with a code snippet that will show the date header when the day changes. You should add the following code to your theme’s functions.php file to make it work:

    https://gist.github.com/vicskf/73fb04230fb4948f53369471787f52ea

    Make sure you don’t add the ‘<?php’ opening tag twice in your file.

    I hope that helps! 🙂

    Cheers!
    Victor

    #1298851
    Robert
    Participant

    Thank you. It works. It would be a nice feature to have a simple checkbox in your plug to choose this display option. It’s important to display the events in a manner that makes sense. That should not be difficult. Thanks again.

    #1299053
    Victor
    Keymaster

    Hi Robert!

    Good to know it worked out for you. Thanks for letting me know.

    I can see the use in having that option in the settings. I encourage you to post that idea in our User Voice here > https://tribe.uservoice.com/, so other users can vote for it and make its way into a future feature release of our plugins.

    I’ll go ahead and close this now, but feel free to open a new one if anything comes up and we’d be happy to help. 🙂

    Best,
    Victor

Viewing 6 posts - 1 through 6 (of 6 total)
  • The topic ‘day and date delineator header in list view’ is closed to new replies.