• Resolved moimoimoi

    (@moimoimoi)


    Hi,

    I don’t want to select the number of tickets but only assign one ticket per user. Is this possible?

    Thanks

Viewing 5 replies - 1 through 5 (of 5 total)
  • richard_vermeer

    (@richard_vermeer)

    I have the same question.

    Hi there,

    While we don’t offer a way to limit tickets “per logged in user”, you could create custom templates to modify the “number” input to have a max of “1”. Note that this would not prevent users from returning to buy the ticket again, only let them add a single ticket at a time.

    Our template views can be overridden by copying the original into a specific folder location in your child theme. The template that you need to work with will depend on whether you are using the “block” or “classic” editor, and if using ET+, a few other factors.

    You can read more about working with custom templates for our plugins here: https://support.theeventscalendar.com/153124-Themers-Guide

    Hope that helps!
    Sky

    richard_vermeer

    (@richard_vermeer)

    Hi Sky,

    Okay, thank you for your reply!

    Regards,

    Richard

    Thread Starter moimoimoi

    (@moimoimoi)

    Hey Sky, thank you for the answer. I will check that. best

    Thread Starter moimoimoi

    (@moimoimoi)

    Hey Sky, works great. But is it normal that I am no longer allowed/cannot update the plugin? Because I edited the form and instead of entering the number manually I set the value to 1. After the last update, I always got the message: “please select the number of tickets”, i.e. there must be something elementary adjusted? Or am I doing something wrong?

    <?php if ( $is_there_any_product_to_sell ) : ?>
    <input type="hidden" class="tribe-ticket-quantity" name="quantity_<?php echo absint( $ticket->ID ); ?>" value="1" >
    <?php if ( -1 !== $available ) : ?>
    <span class="tribe-tickets-remaining">
    <strong><?php $readable_amount = tribe_tickets_get_readable_amount( $available, null, false ); echo sprintf( esc_html__( '%1$s', 'event-tickets' ), '<span class="available-stock" data-product-id="' . esc_attr( $ticket->ID ) . '">' . esc_html( $readable_amount ) . '</span>' );?>
    </strong> .... </span>
    <?php endif; ?>	<?php else: ?>
    <span class="tickets_nostock">
    ....
    </span>
    <?php endif; ?>
    • This reply was modified 4 years, 10 months ago by moimoimoi.
Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Only one ticket per user possible?’ is closed to new replies.