src/libraries/models/Photo.php
/**
    * Output the contents of the original photo
    * Gets a file pointer from the adapter
    *   which can be a local or remote file
    *
    * @param array $photo photo object as returned from the API (not the DB)
    * @return 
    */
Output the contents of the original photo
Gets a file pointer from the adapter
which can be a local or remote file

@param array $photo photo object as returned from the API (not the DB)
@return
Output the contents of the original photo Gets a file pointer from the adapter which can be a local or remote file @param array $photo photo object as returned from the API ( not the DB ) @return
public function download($photo)
  {
    $fp = $this->fs->downloadPhoto($photo);
    if(!$fp)
      return false;
    header('Content-Description: File Transfer');
    header('Content-Disposition: attachment; filename='.$photo['filenameOriginal']);
    while($buffer = fgets($fp, 4096))
      echo $buffer;
    fclose($fp);
  }
public function download ( $ photo ) { $ fp = $ this -> fs -> downloadPhoto ( $ photo ) ; if ( ! $ fp ) return false ; header ( 'Content-Description: File Transfer' ) ; header ( 'Content-Disposition: attachment; filename=' . $ photo [ 'filenameOriginal' ] ) ; while ( $ buffer = fgets ( $ fp , 4096 ) ) echo $ buffer ; fclose ( $ fp ) ; }
Output the contents of the original photo
 Gets a file pointer from the adapter
   which can be a local or remote file
Output the contents of the original photo Gets a file pointer from the adapter which can be a local or remote file