Adding content to ticket email body

Home Forums Ticket Products Event Tickets Plus Adding content to ticket email body

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #1524732
    simpletheory
    Participant

    Is there a way to include the WP username, user’s name, and user’s email address to the email body?

    The ticket email currently includes name of “Purchaser”, but in this case is not as relevant as the user’s name. For example, if a student is going to attend a school show, the parent purchases the ticket, but the ticket needs to have the student’s name on the for admission.

    I am familiar with modifying templates in php, but just need some direction to know how to call these items.

    Thanks!

    #1524893
    Jennifer
    Keymaster

    Hello,

    Thanks for reaching out!

    You can add content to the ticket email by doing a template override – our themer’s guide has instructions on doing this, and the template you’ll want to copy and edit can be found at wp-content/plugins/event-tickets/src/views/tickets/email.php.

    Regarding the specific information you’re wanting to add (username, name, email, etc.), are you using the custom ticket fields to collect this information for each attendee? If not, then this might be your best bet. This post has some example code that you can use to add these fields to the email.

    We are limited in the amount of support that we can provide for customizations, but if you get stuck or have any questions, please let me know – I’ll be happy to point you in the right direction!

    Thanks,

    Jennifer

    #1524899
    simpletheory
    Participant

    Jennifer, thanks for the quick response. I’ve seen that post with the code snippet but I haven’t found the right combinations for my purpose yet.

    The username and email address are collected through the WooCommerce billing details at checkout. If the current email is displaying the billing first/last name, I might be able to figure out how to retrieve these two items.

    I’m looking at the header comment of email.php file and it references “This file is being included in events/lib/tickets/Tickets.php in the function generate_tickets_email_content.”, but I can’t seem to locate Tickets.php. Could you please point me there?

    #1526915
    Jennifer
    Keymaster

    Hello,

    You can find that function here: wp-content/plugins/event-tickets/src/Tribe/Tickets.php, but I’m not sure that it will be particularly helpful with what you’re trying to do…you may instead want to use the order_id to grab the other info from the WooCommerce order.

    If you’d prefer not to tackle this customization on your own, we may be able to assist you further. We do need to prioritize support requests from other customers at this time but I’ll certainly flag this with the team and – although we can’t make any promises – if we have time and space to come back and help, we’ll be happy to do so.  Please let us know if you’d like to go this route so that you can be added to this queue.

    In the meantime, if there is any more information you can share (including mocks) that will help us to better understand what you are seeking please do feel free to add them to this ticket.

    If you urgently need help with this, however, you may instead wish to consider working with a suitably skilled developer or designer who can offer the additional level of support you require.

    Thanks!

    #1527746
    simpletheory
    Participant

    Thanks Jennifer. I have resolved the issue with help from another developer.

    #1528305
    Jennifer
    Keymaster

    Great, I’m glad that you were able to get this resolved! If there is anything else that I can help with, please let me know.

    #1544606
    Support Droid
    Keymaster

    Hey there! This thread has been pretty quiet for the last three weeks, so we’re going to go ahead and close it to avoid confusion with other topics. If you’re still looking for help with this, please do open a new thread, reference this one and we’d be more than happy to continue the conversation over there.

    Thanks so much!
    The Events Calendar Support Team

Viewing 7 posts - 1 through 7 (of 7 total)
  • The topic ‘Adding content to ticket email body’ is closed to new replies.