wx.getImageInfo 本地图可以 网络图片报错为什么?

小程序 文章 2022-03-09 18:40 670 0 全屏看文

AI助手支持GPT4.0

wx.getImageInfo 本地图可以 网络图片报错为什么?wx.getImageInfo This map can be used for network images Why is the error reported?

wx.getImageInfo 本地图可以 网络图片报错为什么?

网络图片报错信息 "getImageInfo:fail download image fail. reason: downloadFile:fail Error: ENOENT: no such file or directory, open ....

网络域名url添加到了downloadFile里了,况且我也没有勾选校验域名,图片网址可以访问到

wx.getImageInfo({

        src:"https://****/images/img1.jpg",

        success (res) {

          console.log(res);

          self.setData({

            width:res.width,

            ytheightimg:res.height,


          })

        },

        fail(err) {

          console.log(err)

        },

d image fail. reason: downloadFile:fail Error: ENOENT: no such file or directory, open 'C:UsersAdministratorAppDataLocal微信开发者工具User Data4ec2a556ea7781d86bd6e9eee09f452fWeappSimulatorWeappFileSystemo6zAJs6VEXTWuNuy771wJxIT98YMwx53ba2293ba2e9c1ftmpqXSespeVJ16x6fec88412eedd2023dd9218c1fde9440.jpg'" "getImageInfo:fail download image fail. reason: downloadFile:fail Error: ENOENT: no such file or directory, open 'C:UsersAdministratorAppDataLocal微信开发者工具User Data4ec2a556ea7781d86bd6e9eee09f452fWeappSimulatorWeappFileSystemo6zAJs6VEXTWuNuy771wJxIT98YMwx53ba2293ba2e9c1ftmpqXSespeVJ16x6fec88412eedd2023dd9218c1fde9440.jpg'"

网络图片报错信息 "getImageInfo:fail download image fail. reason: downloadFile:fail Error: ENOENT: no such file or directory, open .... 网络域名url添加到了downloadFile里了,况且我也没有勾选校验域名,图片网址可以访问到 wx.getImageInfo({ src:"https://****/images/img1.jpg", success (res) { console.log(res); self.setData({ width:res.width, ytheightimg:res.height, }) }, fail(err) { console.log(err) }, d image fail. reason: downloadFile:fail Error: ENOENT: no such file or directory, open 'C:UsersAdministratorAppDataLocal微信开发者工具User Data4ec2a556ea7781d86bd6e9eee09f452fWeappSimulatorWeappFileSystemo6zAJs6VEXTWuNuy771wJxIT98YMwx53ba2293ba2e9c1ftmpqXSespeVJ16x6fec88412eedd2023dd9218c1fde9440.jpg'" "getImageInfo:fail download image fail. reason: downloadFile:fail Error: ENOENT: no such file or directory, open 'C:UsersAdministratorAppDataLocal微信开发者工具User Data4ec2a556ea7781d86bd6e9eee09f452fWeappSimulatorWeappFileSystemo6zAJs6VEXTWuNuy771wJxIT98YMwx53ba2293ba2e9c1ftmpqXSespeVJ16x6fec88412eedd2023dd9218c1fde9440.jpg'"

回答:

八九:

刚加嘛。开发工具>项目配置>刷新下域名信息.再试

紫筱姣姣:域名配置一直都有,wx.getImageInfo是域名配置后才用用到的
王一鸣:

你猜

微喵网络:

图片网址发出来看看

-EOF-

AI助手支持GPT4.0


国内超级便宜服务器

摸鱼人热门新闻聚合

钻级赞助商 我要加入

开发者在线工具

第三方支付技术请加QQ群

相关文章
app开发计步功能,微信有提供获取当日步数的接口吗?如何接入?
微信小程序点击右上角转发时(onShareAppMessa),怎么判断用户是转发成功了?还是取消了?
关于微信小程序授权其它手机号码的问题?
公众号提供的服务故障,工作人员来帮我查啊?
微信公众号网页授权,一个微信号已经同意了userinfo类型的授权,怎么再次拉起授权的弹窗?
随便看看
顾客下单,但是没有信息提示,要在哪里设置? 465
毕设招聘小程序没有人力资源许可证最后可以通过审核发布吗? 535
云开发资源超限停服后需要做什么吗? 546
如何设置一个按钮具备随机抽号的功能呢?小程序支持吗? 380
小程序>添加项目成员,无法通过微信号 搜索 想添加的微信成员(通过微信app是能搜到该用户的!!!) 414
小程序审核通过发布很久了,但是一直搜索不到 412
企微乱封号谁来管?企微官方客服效率低,谁来管?简直就是暴徒行为。。 405
扫码点餐和外卖小程序必须每年各交300元的认证费吗? 556
小程序发布后,搜名字搜不到? 534
我想用云开发做一个咖啡店拼团功能,有没有人有这方面的经验? 456