Posted: April 22, 2019 at 1:13 pm
I see that users get an email which has a link to their ticket. How do I add a column and place this link in the registration list that is placed on the user profile? I would also like to link back to the original event record as well by the name of the event which already has a column. |
|
Hi there,
The table on the user profile can be modified, but to do so you need to load your own custom version of the table. Are you not using the [ESPRESSO_MY_EVENTS] shortcode to output a ‘My Events’ section on the front end for the user? The ticketing add-on automatically adds a link to the ticket on that output. If you specifically want the ticket within the table shown on the profile page, you’ll need to copy the template to your theme’s root directly (preferably a child theme) and then modify the template there. So copy Add an additional column to the table, and then you’ll need some code similar the code on lines 14 through 33 here: https://gist.github.com/Pebblo/e56f98451d1aa0964717 To generate the ticket link for the registration.
My apologies, but I’m not sure what this means. What is the ‘original event record’? The event on the front end? |
|
Yes, the front end event even it it is no longer active. Just as reference. |
|
This reply has been marked as private. | |
On lines 35 – 38 you’ll see the code used to output the link. It checks if the current use can edit the event and if so, outputs the edit event link, if not it outputs the event name. It’s using a ternary if which is essentially
So you want to switch out the You can switch that for something like:
Thank you for the feedback 🙂 If have a minute we would really appreciate if you could share your experience with Event Espresso or provide a review on WP.org. With regards to your other question, I’m not aware of any but I’ll check with the rest of the team. |
|
The output of |
|
Which field do you want to remove? Some of the content is filtered and so you can remove it with a snippet, others you’ll need to copy the template. |
|
Everything from the ‘content edit window’ that comes over. The name, venue, dates and times are fine (although I would like to reformat the date time to something more concise). |
|
This reply has been marked as private. | |
Sorry but that’s a little to vague for me to give an example on 🙂 I can tell you that it sounds like for the info you want to remove you’ll want to edit the templates. You can copy the template files from the plugins If you let me know the specific sections you want to remove, I can give you more specific details if needed. With regards to your other question, I checked and unfortunately, we don’t have any on file that I can share. |
|
Regarding [ESPRESSO_MY_EVENTS] |
|
Ahh, ok, I see. The whole section from the event name to the ‘Your tickets’ heading is your event content so without adding your own classes into the content to then hide using CSS, you’ll lose that whole section including the address and image. So do you still want to remove that? If so you copy To you child theme and remove linee 55. which should be:
|
|
I am using /public_html/wp-content/plugins/eea-wp-user-integration |
|
https://monosnap.com/file/6SrzJaCntGtwKYKOWVhPVtJlpPgmhp Here is the table after: |
|
Hi, May I ask do you now have a template file in your theme that’s name is “content-espresso_my_events-event_section.template.php” and if so, can you share a link to a gist or wpbin or its contents? |
|
This reply has been marked as private. | |
Looks like your’ve removed more than just the code I mentioned above – https://monosnap.com/file/7NNm5Xj5GfpntssyvhZCUb8dsLNAA1 The output in the second screenshot is because you’re getting a fatal error as the syntax is incorrect, it breaks the loops as it removes the section that starts the venues loop. If you revert the code back to the default template (copy the original template to your themes root directory again), then remove only:
It will remove just the event description from the output and you can then work on your ACF fields. |
|
Thank You. |
|
Finally got it to work. Thanks. Opening a new ticket to display the acf in the dropdown. This ticket is off topic. |
|
The support post ‘Allow users to see and print their tickets from website’ is closed to new replies.
Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.