Global navigation

   Documentation Center
   eZ Studio & eZ Platform
     User Manual
     Technical Manual
     Glossary
   eZ Publish 4.x / legacy

 
eZ Publish (5.x)

eZ Publish 5.x | For eZ Platform & eZ Studio topics see Technical manual and User manual, for eZ Publish 4.x and Legacy topics see eZ Publish legacy

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

NameInternal nameExpected inputOutput
BinaryFileezbinaryfileMixedMixed

 

 

Description

This FieldType allows the storage and retrieval of a single file. It is capable of handling virtually any file type and is typically used for storing legacy document types such as PDF files, Word documents, spreadsheets, etc. The maximum allowed file size is determined by the "Max file size" class attribute edit parameter and the "upload_max_filesize" directive in the main PHP configuration file ("php.ini").

API
downloadCount

 Type: integer

Stores the number of times the file was downloaded.

id

Type: string

Binary file identifier. This ID depends on the IO Handler that is being used. With the native, default handlers (FileSystem and Legacy), the ID is the file path, relative to the web root, within the var folder (var/ezdemo_site/storage/original/...).

fileName

Type: string

The actual, physical file name, as exposed to the outside. Used when sending the file for download in order to name the file.

fileSize

Type: integer

The size of the file, in bytes.

mimeType

Type: string

The file's mime type, e.g. application/pdf, text/plain...

uri

Type: string

The binary file's HTTP uri.  How this value is built depends on each IO handler.

path (deprecated)
Type: string
Renamed to id starting from eZ Publish 5.2. Can be used instead of id, but it is better not to use it anymore.