UNB Components Code Reference

UnbMessageRevision::GetFileData method

Gets the contents of an attachment file.

public function UnbMessageRevision::GetFileData ($searchMode = 0);

Parameters

searchMode  –  optional, default: 0
(int) Specifies how to read the data.
* 0: Find the data whereever it is, look in the database first.
* 1: Find the data whereever it is, look in the filesystem first.
* 2: Only read from the database, return null if it's not there.
* 3: Use readfile to read from the filesystem. Returns true or false depending on success.

Return value

the contents of the attached file, or null if there is no file attached. If searchMode is 3, the return value is a boolean value.

Exceptions thrown

UnbDatabaseException No description available.
UnbSecurityException If the message revision was requested with NoContent mode.

Member of class: UnbMessageRevision

Implementation file: messagerevision.class.php, line 1303

© 2010 Yves Goergen. UNB Components Homepage. Reference generated on 2010-03-07.