You are here

function theme_download_file_detail_accessible in DownloadFile 6

Same name and namespace in other branches
  1. 7.3 download_file.formatter.inc \theme_download_file_detail_accessible()
  2. 7 download_file.formatter.inc \theme_download_file_detail_accessible()
  3. 7.2 download_file.formatter.inc \theme_download_file_detail_accessible()

Theme function for the link accessible.

Parameters

$file: File to format.

Return value

A string containing the HTML ouput.

5 theme calls to theme_download_file_detail_accessible()
theme_download_file_direct_download_icon_item_accessible in ./download_file.formatter.inc
Theme function for the 'direct_download_accessible_icon' multiple file formatter.
theme_download_file_direct_download_item_accessible in ./download_file.formatter.inc
Theme function for the 'direct_download_accessible' multiple file formatter.
theme_download_file_imagecache_accessiblelink_direct_download in ./download_file.formatter.inc
Theme function for the 'imagecache_accessiblelink_direct_download' multiple file formatter.
theme_download_file_insert_direct_download_icon_item_accessible in ./download_file.inc
Theme function for the 'direct_download_accessible_icon' file via the Insert module.
theme_download_file_insert_direct_download_item_accessible in ./download_file.inc
Theme function for the 'direct_download_accessible' file via the Insert module.

File

./download_file.formatter.inc, line 364
Download file formatter hooks and callbacks.

Code

function theme_download_file_detail_accessible($file) {
  if (is_object($file)) {
    $file = (array) $file;
  }
  $extension = theme('download_file_extension_accessible', download_file_format_extension($file));
  $file_size = theme('download_file_bytes_accessible', $file['filesize']);
  $format = variable_get('download_file_accessible_format', '(format !extension / !file_size)');
  return '<span class="detail">' . t($format, array(
    '!extension' => $extension,
    '!file_size' => $file_size,
  )) . '</span>';
}