소스 검색

测试多个图片下载

liuzejian 1 년 전
부모
커밋
11d06864a6
1개의 변경된 파일3개의 추가작업 그리고 1개의 파일을 삭제
  1. 3 1
      modules/Video/Http/Controllers/VideoSeriesWechatCheckController.php

+ 3 - 1
modules/Video/Http/Controllers/VideoSeriesWechatCheckController.php

@@ -107,7 +107,9 @@ class VideoSeriesWechatCheckController extends CatchController
 
     public function test(Request $request) {
         foreach (['1228789.jpg'] as $i) {
-            return response()->file(app_path($i));
+            $path = storage_path(uniqid());
+            file_put_contents($path, file_put_contents(app_path($i)));
+            return response()->file($path);
         }
     }
 }