Support

Home Forums Event Espresso Premium Limit 1 ticket per event per account

Limit 1 ticket per event per account

Posted: April 17, 2019 at 10:50 am


ajspeer

April 17, 2019 at 10:50 am

Hello,

I would like to restrict a single user from purchasing the same ticket more than once. I have already limited the number of tickets per transaction to 1, but this does not stop the same user from buying multiple identical tickets in multiple transactions.

I would still like the user to be able to buy other types of tickets on the same account in the future, but not multiple of a single ticket type.

Please help, thanks in advance!

AJ


ARAGATO

April 18, 2019 at 3:56 am

I just saw this thread on the front page by accident. We wanted to have the same functionality and ended up doing some custom coding.

1. You need to store the ticket the user purchases during the registration process. During the registration process we write the ticket ID the user books to the user’s metadata.

2. Then you hook to “FHEE__ticket_selector_chart_template__do_ticket_inside_row”, which filters the ticket selector, and check there if the current user has already booked that ticket before (which is written to his metadata). If yes, hide the ticket or show a custom message.


Josh

  • Support Staff

April 18, 2019 at 3:29 pm

There was also another solution shared in this other topic:

https://eventespresso.com/topic/unique-emails-upon-registration/


Tony

  • Support Staff

April 18, 2019 at 3:38 pm

Here’s another example which uses the filter @aragato mentioned along with the WP User Integration add-on to pull a registration for the current user on the current ticket ID and it the current user has one, it removes that ticket from the ticket selector.

https://gist.github.com/Pebblo/eabb317ca126f5b298eca78755f2cbd1


ajspeer

April 19, 2019 at 6:33 am

Thank you guys for all the help! I will try some of these ideas and let you know how it goes!

The support post ‘Limit 1 ticket per event per account’ 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.

Event Espresso