正在显示
1 个修改的文件
包含
3 行增加
和
2 行删除
| @@ -42,8 +42,9 @@ class TencentCosService extends BaseService | @@ -42,8 +42,9 @@ class TencentCosService extends BaseService | ||
| 42 | */ | 42 | */ |
| 43 | public function upload_image($path,$fileName){ | 43 | public function upload_image($path,$fileName){ |
| 44 | // 构建请求URL | 44 | // 构建请求URL |
| 45 | - $expiredTime = time() + 3600; | ||
| 46 | - $pathname = '/'.$this->config['bucket'].'/'.$fileName; | 45 | + $pathname = '/'.$this->config['bucket'].$path.'/'.$fileName; |
| 46 | + var_dump($pathname); | ||
| 47 | + die(); | ||
| 47 | $signature = $this->generateSignature(); | 48 | $signature = $this->generateSignature(); |
| 48 | $url = 'https://'.$this->config['bucket'].'.cos.'.$this->config['cosRegion'].'.myqcloud.com'.$pathname.'?sign='.$signature; | 49 | $url = 'https://'.$this->config['bucket'].'.cos.'.$this->config['cosRegion'].'.myqcloud.com'.$pathname.'?sign='.$signature; |
| 49 | // 打开文件流 | 50 | // 打开文件流 |
-
请 注册 或 登录 后发表评论