31 Jan
2007
31 Jan
'07
11:07 a.m.
Rob Thorne wrote:
I've done a couple of projects that needed custom "widgets" to use within Forms API, something that you might write into code with something like....
$form['some_text'] = array('#type' => 'textfield', ....); $form['event_date'] = drupal_widget_date($title, $default, $options....); ...
Are you maybe looking for hook_elements? Then you could do: $form['event_date'] = array('#type' => 'my_date', ...); Cheers, Gerhard