function template_preprocess_date_display_range

×

Error message

User warning: The following module is missing from the file system: theme/theme. For information about how to fix this, see the documentation page. in _drupal_trigger_error_with_delayed_logging() (line 1156 of /var/www/html/elmsln_community/api.elmsln.org/includes/bootstrap.inc).
cis7 date.theme template_preprocess_date_display_range(&$variables)
cle7 date.theme template_preprocess_date_display_range(&$variables)
elmsmedia7 date.theme template_preprocess_date_display_range(&$variables)
icor7 date.theme template_preprocess_date_display_range(&$variables)
meedjum_blog7 date.theme template_preprocess_date_display_range(&$variables)
mooc7 date.theme template_preprocess_date_display_range(&$variables)

Template preprocess function for displaying a range of dates.

Related topics

File

sites/all/modules/ulmus/date/date.theme, line 274
Theme functions.

Code

function template_preprocess_date_display_range(&$variables) {
  // Merge in the shared attributes for themes to use.
  $variables['attributes_start'] += $variables['attributes'];
  $variables['attributes_end'] += $variables['attributes'];

  if ($variables['add_rdf']) {
    // Pass along the rdf mapping for this field, if any. Add some default rdf
    // attributes that will be used if not overridden by attributes passed in.
    $dates = $variables['dates'];
    $base_attributes = array(
      'property' => array('dc:date'),
      'datatype' => 'xsd:dateTime',
      'content' => $dates['value']['formatted_iso'],
    );
    $variables['attributes_start'] += $base_attributes;
    $variables['attributes_end'] += $base_attributes;
    $variables['attributes_end']['content'] = $dates['value2']['formatted_iso'];
    foreach ($variables['attributes_end']['property'] as $delta => $property) {
      $variables['attributes_end']['property'][$delta] = str_replace('start', 'end', $property);
    }
  }

  // Pass along microdata attributes, or set display to false if none are set.
  if ($variables['add_microdata']) {
    if (!empty($variables['microdata']['value']['#attributes'])) {
      $variables['microdata']['value']['#attributes']['content'] = $variables['dates']['value']['formatted_iso'];
      $variables['microdata']['value2']['#attributes']['content'] = $variables['dates']['value2']['formatted_iso'];
    }
    else {
      $variables['add_microdata'] = FALSE;
    }
  }
}
Error | ELMSLN API

Error

×

Error message

  • Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/elmsln_community/api.elmsln.org/includes/common.inc:2791) in drupal_send_headers() (line 1499 of /var/www/html/elmsln_community/api.elmsln.org/includes/bootstrap.inc).
  • Error: Call to undefined function apc_delete() in DrupalAPCCache->clear() (line 289 of /var/www/html/elmsln_community/api.elmsln.org/sites/all/modules/apc/drupal_apc_cache.inc).
The website encountered an unexpected error. Please try again later.