function datex_webfrm_form_alter in Datex 7.3
Implements hook_form_alter().
File
- datex_webfrm/
datex_webfrm.module, line 85
Code
function datex_webfrm_form_alter(&$f, &$fs, $form_id) {
if (datex_factory(NULL, NULL, 'en') && isset($f['submitted']) && isset($f['#process']) && is_array($f['#process']) && in_array('webform_client_form_process', $f['#process']) && isset($f['submitted']) && is_array($f['submitted'])) {
foreach ($f['submitted'] as $name => &$el) {
if ($el['#type'] === 'date') {
$el['#process'] = array_merge($el['#process'], [
'_datex_webform_date_element_process',
]);
$el['#element_validate'] = array_merge([
'_datex_webform_date_element_validate',
], $el['#element_validate']);
}
}
}
}