微信回调页面增加除code外其他的自定义参数
1、背景
使用微信回调,通过网页授权,获取code,再通过code获取openid,再根据openid根据自己需要去请求其他接口。但是有时候我们不想返回到页面的只有一个code参数,还想传其他的自定义参数。那么需要怎么做呢?下面分享自己的实现方法,如果有更好的方法,也请各位大佬评论区告知一下,共同进步,本菜鸟不胜感激!
2、回调url拼接案例
https://open.weixin.qq.com/connect/oauth2/authorize?appid=APPID&redirect_uri=REDIRECT_URI&response_typ