You are here

function msnf_step_get_fields in Multistep Nodeform 7

Same name and namespace in other branches
  1. 6 includes/msnf.steps.inc \msnf_step_get_fields()

Function to return a list of field names for a form step of a content type.

Parameters

<string> $content_type: Name of content type.

<string> $step_name: Name of form step.

Return value

<array> List of field names for the form step.

1 call to msnf_step_get_fields()
msnf_steps in includes/msnf.steps.inc
Returns all steps for a content type.

File

includes/msnf.steps.inc, line 361
Step crud functions.

Code

function msnf_step_get_fields($content_type, $step_name) {
  $fields = array();
  $result = db_query("SELECT * FROM {msnf_step_fields} WHERE type_name = '%s' AND step_name = '%s'", array(
    $content_type,
    $step_name,
  ));
  while (($field = db_fetch_array($result)) !== FALSE) {
    $fields[$field['field_name']] = $field;
  }
  return $fields;
}