- Patch #40765 by chx: fixed problem with form types.

4.7.x
Dries Buytaert 2005-12-14 13:22:19 +00:00
parent dd2fdd128d
commit c0a43c50dc
1 changed files with 9 additions and 1 deletions

View File

@ -539,7 +539,15 @@ function expand_date($element) {
$options = drupal_map_assoc(range(1900, 2050));
break;
}
$element[$type] = array('#type' => 'select', '#value' => $element['#value'][$type], '#attributes' => $element['#attributes'], '#parents' => $element['#parents'], '#options' => $options, '#tree' => TRUE);
$parents = $element['#parents'];
$parents[] = $type;
$element[$type] = array(
'#type' => 'select',
'#value' => $element['#value'][$type],
'#attributes' => $element['#attributes'],
'#parents' => $parents,
'#options' => $options,
);
}
return $element;