public function initiateMultipartUpload($bucket, $object, $options = NULL)
    {
        $this->precheckCommon($bucket, $object, $options);
        $options[self::OSS_METHOD] = self::OSS_HTTP_POST;
        $options[self::OSS_BUCKET] = $bucket;
        $options[self::OSS_OBJECT] = $object;
        $options[self::OSS_SUB_RESOURCE] = 'uploads';
        $options[self::OSS_CONTENT] = '';

        if (!isset($options[self::OSS_CONTENT_TYPE])) {
            $options[self::OSS_CONTENT_TYPE] = $this->getMimeType($object);
        }
        if (!isset($options[self::OSS_HEADERS])) {
            $options[self::OSS_HEADERS] = array();
        }
        $response = $this->auth($options);
        $result = new InitiateMultipartUploadResult($response);
        return $result->getData();
    }
public function initiateMultipartUpload($bucket, $object, $options = NULL)
    {
        $this->precheckCommon($bucket, $object, $options);
        $options[self::OSS_METHOD] = self::OSS_HTTP_POST;
        $options[self::OSS_BUCKET] = $bucket;
        $options[self::OSS_OBJECT] = $object;
        $options[self::OSS_SUB_RESOURCE] = 'uploads';
        $options[self::OSS_CONTENT] = '';

        if (!isset($options[self::OSS_CONTENT_TYPE])) {
            $options[self::OSS_CONTENT_TYPE] = $this->getMimeType($object);
        }
        if (!isset($options[self::OSS_HEADERS])) {
            $options[self::OSS_HEADERS] = array();
        }
        $response = $this->auth($options);
        $result = new InitiateMultipartUploadResult($response);
        return $result->getData();
    }
public function initiateMultipartUpload ( $ bucket , $ object , $ options = NULL ) { $ this -> precheckCommon ( $ bucket , $ object , $ options ) ; $ options [ self :: OSS_METHOD ] = self :: OSS_HTTP_POST ; $ options [ self :: OSS_BUCKET ] = $ bucket ; $ options [ self :: OSS_OBJECT ] = $ object ; $ options [ self :: OSS_SUB_RESOURCE ] = 'uploads' ; $ options [ self :: OSS_CONTENT ] = '' ; if ( ! isset ( $ options [ self :: OSS_CONTENT_TYPE ] ) ) { $ options [ self :: OSS_CONTENT_TYPE ] = $ this -> getMimeType ( $ object ) ; } if ( ! isset ( $ options [ self :: OSS_HEADERS ] ) ) { $ options [ self :: OSS_HEADERS ] = array ( ) ; } $ response = $ this -> auth ( $ options ) ; $ result = new InitiateMultipartUploadResult ( $ response ) ; return $ result -> getData ( ) ; }
Initialize a multi-part upload

@param string $bucket bucket name
@param string $object object name
@param array $options Key-Value array
@throws OssException
@return string returns uploadid
Initialize a multi - part upload