Hello. I love this module! One issue I'm running into is that we sometimes want to limit the number of times a given form can be submitted, e.g. to limit the number registrations for an event. As a temporary fix I'm using the following code in the "Additional processing" field:

# Unpublish the form if it has more than 22 registrants.
$count = db_fetch_array(db_query("SELECT COUNT(sid) AS regs FROM {webform_submissions} WHERE nid = %d",$node->nid));
if ($count['regs'] > 22) {
  $node->status = 0;
  node_save($node);
}

But it would be nice if we could have that as a setting in the form instead. Is there an existing module or patch that adds this functionality? If not, I may be motivated to contribute one. :-) Thanks again.

Comments

quicksketch’s picture

Status: Active » Closed (duplicate)