在获取微信openId时携带的参数为null

在获取微信code 之后,我们进行 redirect  重定向  获取微信 openid

http://projectgetOpenId?sid=1 ........

在重定向的get  请求中携带一个自定义参数例如sid  ,在获取微信openId  接口  

String sid = request.getParameter("sid");取出是没有问题的。

但是业务需要多携带一个参数。再次加到获取微信  openId 的get 请求中

http://projectgetOpenId?sid=1&type=3 ........

在微信openId  接口  

String sid = request.getParameter("sid");

String type= request.getParameter("type");

type 等于null  ,  微信不予许传入两个参数

原文地址:https://www.cnblogs.com/blogspring/p/14191775.html