You are here

function date_element_info in Date 7

Same name and namespace in other branches
  1. 8 date.module \date_element_info()
  2. 7.3 date.module \date_element_info()
  3. 7.2 date.module \date_element_info()

Implements hook_element_info().

date_combo will create a 'from' and optional 'to' date, along with an optional 'timezone' column for date-specific timezones. Each 'from' and 'to' date will be constructed from date_select or date_text.

File

./date.module, line 235

Code

function date_element_info() {
  $type = array();
  $type['date_combo'] = array(
    '#input' => TRUE,
    '#delta' => 0,
    '#columns' => array(
      'value',
      'value2',
      'timezone',
      'offset',
      'offset2',
    ),
    '#process' => array(
      'date_combo_element_process',
    ),
    '#element_validate' => array(
      'date_combo_validate',
    ),
    '#value_callback' => 'date_combo_value_callback',
    '#theme_wrappers' => array(
      'date_combo',
    ),
  );
  return $type;
}