You are here

function _webform_validation_all_allowed in Webform Validation 6

Helper function to check whether all components are allowed to be used for a certain validator

1 call to _webform_validation_all_allowed()
webform_validation_valid_component_types in ./webform_validation.validators.inc
Get a list of valid component types per validator, as defined via hook_webform_validation_validators(). If 'all' is specified, all available component types will be returned.

File

./webform_validation.validators.inc, line 576
Provides validation functionality and hooks

Code

function _webform_validation_all_allowed($allowed) {
  if ($allowed) {
    foreach ($allowed as $type) {
      if ($type == "all") {
        return TRUE;
      }
    }
  }
  return FALSE;
}