微信小程序之授权登录--项目需要

1.由于项目需要,需要实现自己的微信小程序 用微信授权登录。
2.参考此项目https://blog.csdn.net/weidong_y/article/details/79636386
3.其中的问题就是:获取openid 不能在前端小程序实现。报错【 https://api.weixin.qq.com 不在以下 request 合法域名列表中,请参考文档:https://mp.weixin.qq.com/debug/wxadoc/dev/api/network-request.html】
4.解决方法,微信禁止了。
5。他那个个后端去实现。获取微信openid等接口必须通过自己的服务器去调用,小程序是不支持像android等app直接调用的,因为 api.weixin.qq.com不能在小程序中配置为域名
6.https://www.seoxiehui.cn/article-109953-1.html --第一种前端实现
https://www.cnblogs.com/legendheng/p/9469173.html 第二种后端

发布了90 篇原创文章 · 获赞 28 · 访问量 8万+

猜你喜欢

转载自blog.csdn.net/qq_27300101/article/details/102798917