Displaying Attendee List on Front End (single event)

Home Forums Ticket Products Event Tickets Plus Displaying Attendee List on Front End (single event)

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #966699
    Drew Poland
    Participant

    Hey MT!

    I’m trying to display an attendee list inside the sigle-event template, only visible to admins & event owner (author).

    This works.. but its showing every ticket they have ever sold and to any event?

    https://gist.github.com/bmoredrew/dcc7d04b23e785f6c0bb

    Any help appreciated as I’m sure this is out of scope of support.

    #966905
    Nico
    Member

    Hi Drew,

    Thanks for reaching out! Nice piece of code 🙂

    Tested it on my end and it’s working as expected. If <b>get_event_attendees</b> is used without passing the Event ID as parameter it shows every ticket sold to every event. So maybe what’s happening is that $event_id is not holding the correct Event ID value or is NULL. Can you test this? Where are you placing this inside the template?

    Let me know if my theory is right. Anyway I’m sure it’s a minor thing as it worked on my end,
    Best,
    Nico

    #967018
    Drew Poland
    Participant

    ah, hah! I’m including this code as a template part in single-vent.php, so I thought event_id would waterfall into my code but it wasn’t getting passed in for some reason. Added it and that fixed it.

    Thank so much!!

    #967019
    Drew Poland
    Participant

    marking resolved, thanks again!

    #967035
    Nico
    Member

    You are welcome Drew, always happy to help 🙂

    I’m going to close this topic – but please don’t hesitate to create new topics if you need help with anything else.

    Have a great Wednesday,
    Nico

Viewing 5 posts - 1 through 5 (of 5 total)
  • The topic ‘Displaying Attendee List on Front End (single event)’ is closed to new replies.