Send email on attendees update (hook `event_tickets_after_attendees_update`)

Home Forums Ticket Products Event Tickets Plus Send email on attendees update (hook `event_tickets_after_attendees_update`)

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #1371466
    David Hager
    Participant

    This seems like a custom function that you don’t do support for I know, but I think I’m already 80% there. I would like to get an email when a user edits/updates their ticket after they bought them.

    I have found the function event_tickets_after_attendees_update and thought this would trigger when I update the the ticket over at domain.com/event/name-event/ticket and hit this button

    <div class="tribe-submit-tickets-form">
      <button type="submit" name="process-tickets" value="1" class="button alt">Update ticket</button>
    </div>

    I have created the following function that has the hook in it that I mention earlier

    function alloyMailWhenTicketUpdate() {
    
      wp_mail(
        '[email protected]',
        'updated',
        'A ticket as updated'
      );
    }
    
    add_action('event_tickets_after_attendees_update', 'alloyMailWhenTicketUpdate');

    But it seems not to trigger, is there another hook that I can latch on to to get notified when a user updates their ticket?

    #1371580
    David Hager
    Participant

    Seems like the culprit was my local environment it works fine on my live site.

    #1371783
    Geoff B.
    Member

    Good evening David and welcome back!

    Thank you for reaching out to us.

    Major kudos for that snippet and thank you for sharing!

    You are welcome back in our support forums any time 🙂

    For now, I am going to close this thread.

    Have a great week!

    Geoff B.

Viewing 3 posts - 1 through 3 (of 3 total)
  • The topic ‘Send email on attendees update (hook `event_tickets_after_attendees_update`)’ is closed to new replies.