Commit 2daf89e0 authored by Live's avatar Live Committed by Gitee

HttpUtils.sendPost()方法,参数无需拼接参数到url,否则会出现双份参数

请求url或form参数 会出现双份参数,并无法获取
{"token":["xxxxxxx","xxxxxxx"],"payType":["weixin","weixin"],"amount":["100","100"],"orderId":["123","123"]}
parent a2d11602
......@@ -118,7 +118,7 @@ public class HttpUtils
StringBuilder result = new StringBuilder();
try
{
String urlNameString = url + "?" + param;
String urlNameString = url;
log.info("sendPost - {}", urlNameString);
URL realUrl = new URL(urlNameString);
URLConnection conn = realUrl.openConnection();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment