function _webform_client_form_submit_process in Webform 5
Same name and namespace in other branches
- 5.2 webform.module \_webform_client_form_submit_process()
- 6.3 webform.module \_webform_client_form_submit_process()
- 6.2 webform.module \_webform_client_form_submit_process()
- 7.4 webform.module \_webform_client_form_submit_process()
- 7.3 webform.module \_webform_client_form_submit_process()
Post processes the submission tree with any updates from components.
1 call to _webform_client_form_submit_process()
File
- ./
webform.module, line 1630
Code
function _webform_client_form_submit_process($node, &$form_values, $parent = 0) {
if (is_array($form_values)) {
foreach ($form_values as $form_key => $value) {
$cid = webform_get_cid($node, $form_key, $parent);
if (is_array($value) && $node->webformcomponents[$cid]['type'] == 'fieldset') {
_webform_client_form_submit_process($node, $form_values[$form_key], $cid);
}
}
}
// We loop through components rather than the actual submission, because
// some components (file) do not get things submitted in the $form_values.
foreach ($node->webformcomponents as $cid => $component) {
if ($component['parent'] == $parent) {
$submit_function = "_webform_submit_" . $component['type'];
if (function_exists($submit_function)) {
$submit_function($form_values[$component['form_key']], $component);
// Call the component process submission function.
}
}
}
}