怎样实现图片的统一上传?

小程序 文章 2022-04-02 09:40 427 0 全屏看文

AI助手支持GPT4.0

怎样实现图片的统一上传?How to achieve unified upload of pictures?

怎样实现图片的统一上传?

我是想先用wx.chooseImage多次选择多张图片,临时路径统一存到一个数组中,后面再读出数组中的临时路径,用wx.uploadFile将选择的图片依次上传到云端中,请问这思路对吗?


I want to use Wx first Chooseimage selects multiple pictures for many times, and the temporary paths are uniformly stored in an array. Then read out the temporary paths in the array, and use Wx UploadFile uploads the selected pictures to the cloud in turn. Is this right?

回答:

八九:

可行的

那一抹笑😃 穿透阳光:

思路可以,这样的话就是一个选择按钮,一个上传按钮

郑旭东:

也可以优化一下,多张图片并发上传,会快一些。

wdcheng:你指的是图片选择时count 设为多张吗?但我选择上传的图片可能会大于9张;

-EOF-

AI助手支持GPT4.0