donglu9445 2017-04-21 04:42
浏览 96

我可以使用PHP直接上传到Amazon S3存储桶而无需将其保存在本地系统中吗?

I am taking the input of a file using multipart form data using a post form over the cloud. Can I be able to upload it directly to the Amazon S3 Bucket without saving it on the local system? I tried it by saving on the local system and then uploading it to the s3 Bucket. It worked fine but I want to know that can it be uploaded directly using the post form without saving it to the local system.

  • 写回答

1条回答 默认 最新

  • douchuitang0642 2017-04-21 04:55
    关注

    it could probably be done with stream wrapper of the S3 SDK. Read in chunks from php://input and write to s3, however, php://input is not available with enctype="multipart/form-data".

    But why not upload to your S3 bucket directly from the client using a presigned POST URL?

    评论

报告相同问题?

悬赏问题

  • ¥15 如何在scanpy上做差异基因和通路富集?
  • ¥20 关于#硬件工程#的问题,请各位专家解答!
  • ¥15 关于#matlab#的问题:期望的系统闭环传递函数为G(s)=wn^2/s^2+2¢wn+wn^2阻尼系数¢=0.707,使系统具有较小的超调量
  • ¥15 FLUENT如何实现在堆积颗粒的上表面加载高斯热源
  • ¥30 截图中的mathematics程序转换成matlab
  • ¥15 动力学代码报错,维度不匹配
  • ¥15 Power query添加列问题
  • ¥50 Kubernetes&Fission&Eleasticsearch
  • ¥15 報錯:Person is not mapped,如何解決?
  • ¥15 c++头文件不能识别CDialog