function theme_feeds_upload

cis7 feeds.pages.inc theme_feeds_upload($variables)
cle7 feeds.pages.inc theme_feeds_upload($variables)
elmsmedia7 feeds.pages.inc theme_feeds_upload($variables)
icor7 feeds.pages.inc theme_feeds_upload($variables)
meedjum_blog7 feeds.pages.inc theme_feeds_upload($variables)
mooc7 feeds.pages.inc theme_feeds_upload($variables)

Theme upload widget.

2 string references to the theme hook from theme_feeds_upload()

Note: this list is generated by looking for the string for this theme hook, so it may include some references that are not actually using this theme hook.

FeedsFileFetcher::sourceForm in sites/all/modules/ulmus/feeds/plugins/FeedsFileFetcher.inc
Source form.
feeds_theme in sites/all/modules/ulmus/feeds/feeds.module
Implements hook_theme().

File

sites/all/modules/ulmus/feeds/feeds.pages.inc, line 334
Menu callbacks, form callbacks and helpers.

Code

function theme_feeds_upload($variables) {
  $element = $variables['element'];
  drupal_add_css(drupal_get_path('module', 'feeds') . '/feeds.css');
  _form_set_class($element, array('form-file'));
  $description = '';
  if (!empty($element['#file_info'])) {
    $file = $element['#file_info'];
    $wrapper = file_stream_wrapper_get_instance_by_uri($file->uri);
    $description .= '<div class="file-info">';
    $description .= '<div class="file-name">';
    $description .= l($file->filename, $wrapper->getExternalUrl());
    $description .= '</div>';
    $description .= '<div class="file-size">';
    $description .= format_size($file->filesize);
    $description .= '</div>';
    $description .= '<div class="file-mime">';
    $description .= check_plain($file->filemime);
    $description .= '</div>';
    $description .= '</div>';
  }
  $description .= '<div class="file-upload">';
  $description .= '<input type="file" name="' . $element['#name'] . '"' . ($element['#attributes'] ? ' ' . drupal_attributes($element['#attributes']) : '') . ' id="' . $element['#id'] . '" size="' . $element['#size'] . "\" />\n";
  $description .= '</div>';
  $element['#description'] = $description;

  // For some reason not unsetting #title leads to printing the title twice.
  unset($element['#title']);
  return theme('form_element', $element);
}
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.