I need to build a webform where one of the questions asks the user to pick a date from a list of 5 dates. Each of the 5 dates only allows 10 attendees. How can I track the number of people that have registered for each date and limit the number of attendees? Thanks for any help.

Comments

Stefan Lehmann’s picture

Don't think you'll find a ready made solution for that.

Easiest would be to attach your own validation function to the webform via hook_form_alter and attaching your own function to $form['#validate'][] .. There should be examples floating around.

As to actually finding out how many people registered for which option. You'll either have to build your own query or use webform_get_submissions() to get all submissions and iterate through them.

But yeah .. don't think you'll find something where you don't have to code at least a bit. Also if you're really on Drupal 4.5.x or older .. Good luck. You'll need it.

I like cookies!