You are here

function _webform_csv_data_date in Webform 7.3

Same name and namespace in other branches
  1. 5.2 components/date.inc \_webform_csv_data_date()
  2. 5 components/date.inc \_webform_csv_data_date()
  3. 6.3 components/date.inc \_webform_csv_data_date()
  4. 6.2 components/date.inc \_webform_csv_data_date()
  5. 7.4 components/date.inc \_webform_csv_data_date()

Implements _webform_csv_data_component().

File

components/date.inc, line 432
Webform module date component.

Code

function _webform_csv_data_date($component, $export_options, $value) {
  if ($value[0]) {
    $timestamp = webform_strtotime($value[0]);
    $format = webform_date_format('short');
    return format_date($timestamp, 'custom', $format, 'UTC');
  }
  else {
    return '';
  }
}