wx.getUserInfo返回问题? 和wx.openSetting问题....?

小程序 文章 2021-04-03 21:22 460 0 全屏看文

AI助手支持GPT4.0

wx.getUserInfo返回问题? 和wx.openSetting问题....?wx.getUserInfo returns a problem? and wx.openSetting problem...?

wx.getUserInfo返回问题? 和wx.openSetting问题....?

第一个关于wx.getUserInfo的问题:

代码如下:

但是返回的用户信息根本不是我的信息,如下 :

假如调整一下代码,如下 :

返回'未授权',如下 :

我之前是授权过的,可能后来又拒绝了,不知道这是怎么回事?

第二个问题:就是在button中用openSetting,没有用户信息授权选项,难道拒绝一次,终身不能再用了吗???,代码如下:

打开页面:

打开页面后,却没有再次获取用户信息授权的选项,怎么办??????:




The first one is about wx.getUserInfo Question: the code is as follows: but the returned user information is not my information at all, as follows: if you adjust the code, as follows: return 'unauthorized', as follows: I have authorized before, but may later refuse, I don't know what's the matter? Second question: open setting is used in button, and there is no user information authorization option, Can you refuse once and never use it again? The code is as follows: open the page: after opening the page, you don't have the option to obtain user information authorization again. What should you do

回答:

圣殿骑士:

需要提前更新成 getUserProfile

线上要到4月13日才会完全改成新的,但是现在的开发环境包括IDE工具已经更新成新的方案。

如果你当心到时候无法顺利切换,可以使用 wx.canIUse

这个方法来判断 getUserProfile 来做切换


张倩:2000000000
|G.XIAO|:

周知:getUserInfo 开发版 & 体验版 已对齐 getUserInfo 匿名表现,正式版将于 4月13日 正式对齐 getUserInfo 匿名表现。请开发者使用 getUserProfile 获取用户信息。


小程序登录、用户信息相关接口调整说明:https://developers.weixin.qq.com/community/develop/doc/000cacfa20ce88df04cb468bc52801


getUserProfile

-EOF-

AI助手支持GPT4.0


国内超级便宜服务器

摸鱼人热门新闻聚合

钻级赞助商 我要加入

开发者在线工具

第三方支付技术请加QQ群

相关文章
button设置active后长按效果不恢复,不设置少了点击反馈?真机测试没问题。
买家恶意不断申请仅退款,不退货,那怎么办?
wx.shareAppMessage的query长度是否有限制?
小程序登录不了,点击登录授权后提示“系统信息 请先登录”,这是怎么回事?
产品不支持广告如何变现?
随便看看
教育科技公司申请微信支付被拒绝? 4798
微信公众号免300认证教程 5892
小程序已经上线,作为管理员无法在小程序数据助手查看数据? 5299
小程序广告组件通过审核,但是小程序内没有显示广告? 5067
企业微信通讯录账号被管理员误/恶意删除,怎么办? 9568
问题? 9048
如何快速搭建抽奖助手小程序(无需代码知识) 6177
许涛 大哥在吗, 要解冻小程序的时候提示信息主体不一致, 能帮忙看下吗? 7472
小程序搜一搜全称搜索不显示 麻烦解决一下!谢谢 6793
我的小程序广告收款主体是个体工商户,每个月邮寄两次发票很是麻烦,我年底的时候打包邮寄一次可以么? 6127