Support

Home Forums Event Espresso Premium Minimum Attendance

Minimum Attendance

Posted: April 6, 2017 at 4:07 pm

Viewing 1 reply thread


Weldon Dodd

April 6, 2017 at 4:07 pm

We run training classes that are only “guaranteed to run” if we hit a certain # of students. Is there a way to set this minimum as another attribute of the event and then use conditionals to display one message if the class could still be canceled and another message if it is “guaranteed to run” on that date?


Josh

  • Support Staff

April 6, 2017 at 9:28 pm

Hi Weldon,

Yes, there are ways to make this happen. Here’s one way:

Step 1) You add this code to your website:
https://gist.github.com/joshfeck/6238632eee8f83f3d8c9a676580907f5
You can add the above to a functions plugin or into your WordPress theme’s functions.php file.

Step 2) When you set up an event/class in the Event Espresso > Events > Add new event page, you add a new custom field, name it minimum, and set its value to the number of students required. The custom field metabox will look something like this when it’s ready:

https://www.evernote.com/l/AARM8bX8D5JJgajN-ksmzDVtpj0Mz0L4JsQB/image.png

You can also use a plugin like Advanced Custom Fields to make a nicer looking/working Custom field box.

Viewing 1 reply thread

The support post ‘Minimum Attendance’ 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