theme_date

  1. drupal
    1. 5
    2. 6
    3. 7
    4. 8
Versions
5 – 6 theme_date($element)
8 – 7 theme_date($variables)

Returns HTML for a date selection form element.

Parameters

$variables An associative array containing:

  • element: An associative array containing the properties of the element. Properties used: #title, #value, #options, #description, #required, #attributes.

Related topics

Code

includes/form.inc, line 2813

<?php
function theme_date($variables) {
  $element = $variables['element'];

  $attributes = array();
  if (isset($element['#id'])) {
    $attributes['id'] = $element['#id'];
  }
  if (!empty($element['#attributes']['class'])) {
    $attributes['class'] = (array) $element['#attributes']['class'];
  }
  $attributes['class'][] = 'container-inline';

  return '<div' . drupal_attributes($attributes) . '>' . drupal_render_children($element) . '</div>';
}
?>