Help with WP_Query: How do I display a simple list of events?

Home Forums Calendar Products Events Calendar PRO Help with WP_Query: How do I display a simple list of events?

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #46185
    blogjunkie
    Participant

    By default TEC splits events into Upcoming and Past events. For the site that I’m currently building, I’m overriding the default template with ~/mytheme/events/list.php. I’ve got it styled the way I want but I can’t figure out how to show a simple list of events (without splitting into Upcoming and Past) that respects pagination.

    This would be simple to do if I had created my own Custom Post Type for Events, but I wanted to take advantage of all the features provided in TEC. Here’s a visual representation of what I want to achieve:

    Events
    ====
    Event starting May 10
    Event starting May 9
    Event starting May 8
    Event starting May 7
    Event starting May 6
    ← Previous Events

    Events (Page 2)
    ====
    Event starting May 5
    Event starting May 4
    Event starting May 3
    Event starting May 2
    Event starting May 1
    ← Previous Events | Next Events →

    #46238
    Jonah
    Participant

    Hey blogjunkie,

    You can use this sample code to get you started: https://gist.github.com/jo-snips/5112025

    You’ll need to build in pagination and customize other things yourself though.

    I hope that helps!

    – Jonah

Viewing 2 posts - 1 through 2 (of 2 total)
  • The topic ‘Help with WP_Query: How do I display a simple list of events?’ is closed to new replies.