Specify Content-Type in AWS PHP's upload function

前端 未结 2 682
再見小時候
再見小時候 2021-01-06 08:31

I am migrating my code from AWS PHP SDK1 to SDK2 (https://github.com/aws/aws-sdk-php).

I have an image uploader. In my previous version, I would specify the Content-

2条回答
  •  轻奢々
    轻奢々 (楼主)
    2021-01-06 09:06

    At the end, this set of options worked:

    array('params' => array('ContentType' => $mime))
    

    No need for Metadata

提交回复
热议问题