function msnf_pre_render in Multistep Nodeform 7
Function to pre render the step element.
Parameters
<array> $element: Element to render.
<object> $step: The current step object.
<array> $form: The form that contains the element.
See also
1 call to msnf_pre_render()
- msnf_fields_nest in ./
msnf.module - Recursive function to nest fields in the steps.
File
- ./
msnf.module, line 994 - Main functions for module "Multistep Nodeform".
Code
function msnf_pre_render(&$element, $step, &$form) {
// Only run the pre_render function if the step has elements.
if ($element == array()) {
return;
}
// Let modules define their wrapping element.
// Note that the step element has no properties, only elements.
foreach (module_implements('msnf_step_pre_render') as $module) {
$function = $module . '_msnf_step_pre_render';
if (function_exists($function)) {
// The intention here is to have the opportunity to alter the
// elements, as defined in hook_msnf_formatter_info.
// Note, implement $element by reference!
$function($element, $step, $form);
}
}
// Allow others to alter the pre_render.
drupal_alter('msnf_pre_render', $element, $step, $form);
}