(PECL mongo >=0.9.0)

MongoGridFSFile::getBytesReturns this file's contents as a string of bytes


public MongoGridFSFile::getBytes ( void ) : string

Warning: this will load the file into memory. If the file is bigger than your memory, this will cause problems!

Elenco dei parametri

Questa funzione non contiene parametri.

Valori restituiti

Returns a string of the bytes in the file.


Example #1 MongoGridFSFile::getBytes() example



$image $images->findOne('jwage.png');

header('Content-type: image/png;');
add a note add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top