首次使用微信登陆时,调用微信开放平台的授权登录,访问此页面https://open.weixin.qq.com/connect/qrconnect?appid=xxxx&redirect_uri=http://xxxx.com/xx/xxx&response_type=code&scope=snsapi_login&state=staate#wechat_redirect,并在此页面扫码,但是,访问我的回调地址http://xxxx.com/xx/xxx时,没有携带参数code和state,登录无法进行,第二次访问并扫码时,回调地址就能获取到code参数,怎么回事?如何修改?

你好,请问是网站应用微信登陆吗?麻烦参考接口文档进行下一步操作哈https://developers.weixin.qq.com/doc/oplatform/Website_App/WeChat_Login/Wechat_Login.html