You are here

function webform_validation_get_all_components in Webform Validation 6

Same name and namespace in other branches
  1. 7 webform_validation.rules.inc \webform_validation_get_all_components()

Get info on all components that are available on a webform

1 call to webform_validation_get_all_components()
webform_validation_get_rule_components in ./webform_validation.rules.inc
Get an array of components linked to a rule

File

./webform_validation.rules.inc, line 59
provides API and management functions for the webform validation rules

Code

function webform_validation_get_all_components($nid) {
  $components = array();
  $result = db_query("SELECT * FROM {webform_component} WHERE nid = %d", $nid);
  while ($row = db_fetch_array($result)) {
    $components[$row['cid']] = $row;
  }
  return $components;
}