|
...
|
...
|
@@ -59,8 +59,7 @@ class ImageController |
|
|
|
[$last_modified_time, $hash . ':' . $w . '_' . $h . '_' . 2, $last_modified_time], $this->upload_img['header']);
|
|
|
|
$content = file_get_contents($filename);
|
|
|
|
$header['Content-Length'] = $info['size'];
|
|
|
|
return response($content, 200, $header);
|
|
|
|
}
|
|
|
|
}else{
|
|
|
|
$path = $info['path'];
|
|
|
|
if (!is_file($path)) {
|
|
|
|
$this->response('指定图片已被系统删除!', Code::USER_ERROR);
|
|
...
|
...
|
@@ -77,6 +76,7 @@ class ImageController |
|
|
|
$content = file_get_contents($path);
|
|
|
|
$header['Content-Length'] = $info['size'];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
$img_type = $info['type'];
|
|
|
|
$content = base64_encode($content);
|
|
|
|
$img_base64 = 'data:image/' . $img_type . ';base64,' . $content;
|
...
|
...
|
|