You are here

function theme_filefield_item in FileField 6.3

Theme function for any file that is managed by FileField.

It doesn't really format stuff by itself but rather redirects to other formatters that are telling us they want to handle the concerned file.

This function checks if the file may be shown and returns an empty string if viewing the file is not allowed for any reason. If you need to display it in any case, please use theme('filefield_file') instead.

1 theme call to theme_filefield_item()
theme_filefield_formatter_default in ./filefield_formatter.inc
Theme function for the 'default' filefield formatter.

File

./filefield_formatter.inc, line 87
FileField: Defines a CCK file field type.

Code

function theme_filefield_item($file, $field) {
  if (filefield_view_access($field['field_name']) && filefield_file_listed($file, $field)) {
    return theme('filefield_file', $file);
  }
  return '';
}