获得Object内容
public get_object ( $bucket, string $object, array $options = null ) : ResponseCore | ||
$object | string | (Required) |
$options | array | (Optional) |
리턴 | ResponseCore |
function ftp_get($file, $path) { $obj = new ALIOSS(); $obj->set_host_name($this->hostname, $this->port); $obj->set_debug_mode(FALSE); $bucket = $this->bucket; $file = jishigou_oss::clear($file); $path = jishigou_oss::clear($path); $options = array(ALIOSS::OSS_FILE_DOWNLOAD => $path); $response = $obj->get_object($bucket, $file, $options); $rt = jishigou_oss::status($response); return $rt == '2' ? 1 : 0; }