wx.chooseImage选择不上图片?
发布于 5 年前 作者 maoxia 6858 次浏览 来自 官方Issues

wx.chooseImage

从本地相册选择图片或使用相机拍照点完成之后返回失败fail

3 回复

这边测试是正常的,麻烦提供出现问题的具体机型、微信版本号、系统版本号,以及能复现问题的代码片段(https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html

wx.chooseImage({

count: 6,

sizeType: [‘original’, ‘compressed’],

sourceType: [‘album’, ‘camera’],

success: function (res) {

const images = that.data.addimgs.concat(res.tempFilePaths)

that.pushImg(images);

},

});

直接在开发者工具跑能打开的,手机上也是也可以的,建议仔细检查下代码

回到顶部