Limit places at events

Home Forums Welcome! Pre-Sales Questions Limit places at events

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #996546
    Nick
    Participant

    Hello,

    is it possible to set a limit to the amount of places/tickets that an event is able to offer?

    If so, is it possible to show a warning when tickets/places for that event are running low? i.e ‘only 5 places left, book now!’

    Thanks

    #996620
    George
    Participant

    Hey Nick!

    For actually setting a limit on number of tickets available for an event, it seems like the default “Ticket Stock” option would work great for this. Here’s a screenshot of what I’m referring to, just to be 100% clear → https://cloudup.com/cKOb4GTVzGB

    Now, as for displaying a message when the ticket stock is low, that would unfortunately require some custom code. We don’t offer support for custom code, technically, but I do have some code that you can use for reference here → https://gist.github.com/ggwicz/e4d0d46cdf6d3977e5bc#file-ticket-stock-example-php

    When you use that function, as it stands right now it will just display the ticket stock numbers on the front-end of your site. But notice the $ticket->stock variable down at the end of line 27 in that file?

    Well, if you simply add some extra code here that displays a message when it is less than nor equal to 5 (i.e. when only 5 or fewer tickets remain…), then you should be good to go here. Something like:


    if ( $ticket->stock && 5 <= $ticket->stock ) {
    printf( 'Only %s tickets remain, book now!', $ticket->stock );
    }

    I hope that helps, cheers!

    — George

    #1000850
    Support Droid
    Keymaster

    This topic has not been active for quite some time and will now be closed.

    If you still need assistance please simply open a new topic (linking to this one if necessary)
    and one of the team will be only too happy to help.

Viewing 3 posts - 1 through 3 (of 3 total)
  • The topic ‘Limit places at events’ is closed to new replies.