微信小程序downloadFile下载问题

发布于 7 年前作者 olu9031 次浏览最后编辑 7 年前来自 ask

wx.downloadFile({

url: image,

success: res => {

if (res.statusCode == 200){

file.push(res.tempFilePath)

console.log(file)

}

}

})

image为网络图片路径

statusCode == 200 但是没有下载对应文件

报错Failed to load local image resource

使用

wx.downloadFile突然报错fail Error: Exceeded maxRedirects. Probably stuck in a redirect loop,之前还是正常的,连续几次之后报错了,求解决

在线等。。。很急。。。

1 回复
ekong
ekong1 楼5 年前

麻烦提供能复现问题的代码片段(https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html