src/Dropbox/Dropbox.php
public function upload($dropboxFile, $path, array $params = [])
    {
        //Make Dropbox File
        $dropboxFile = $this->makeDropboxFile($dropboxFile);

        //If the file is larger than the Chunked Upload Threshold
        if ($dropboxFile->getSize() > static::AUTO_CHUNKED_UPLOAD_THRESHOLD) {
            //Upload the file in sessions/chunks
            return $this->uploadChunked($dropboxFile, $path, null, null, $params);
        }

        //Simple file upload
        return $this->simpleUpload($dropboxFile, $path, $params);
    }
public function upload($dropboxFile, $path, array $params = [])
    {
        //Make Dropbox File
        $dropboxFile = $this->makeDropboxFile($dropboxFile);

        //If the file is larger than the Chunked Upload Threshold
        if ($dropboxFile->getSize() > static::AUTO_CHUNKED_UPLOAD_THRESHOLD) {
            //Upload the file in sessions/chunks
            return $this->uploadChunked($dropboxFile, $path, null, null, $params);
        }

        //Simple file upload
        return $this->simpleUpload($dropboxFile, $path, $params);
    }
public function upload ( $ dropboxFile , $ path , array $ params = [ ] ) { //Make Dropbox File $ dropboxFile = $ this -> makeDropboxFile ( $ dropboxFile ) ; //If the file is larger than the Chunked Upload Threshold if ( $ dropboxFile -> getSize ( ) > static :: AUTO_CHUNKED_UPLOAD_THRESHOLD ) { //Upload the file in sessions/chunks return $ this -> uploadChunked ( $ dropboxFile , $ path , null , null , $ params ) ; } //Simple file upload return $ this -> simpleUpload ( $ dropboxFile , $ path , $ params ) ; }
Upload a File to Dropbox

@param  string|DropboxFile $dropboxFile DropboxFile object or Path to file
@param  string             $path        Path to upload the file to
@param  array              $params      Additional Params

@link https://www.dropbox.com/developers/documentation/http/documentation#files-upload

@return \Kunnu\Dropbox\Models\FileMetadata
Upload a File to Dropbox