所有栏目 | 云社区 美国云服务器[国内云主机商]
你的位置:首页 > 云社区 » 正文

ajaxpost带参数请求后台怎么接收参数?

发布时间:2020-04-15 16:50:20

资讯分类:ajaxpost  参数  后台  接收  传入  字符串  即可
ajaxpost带参数请求后台怎么接收参数?

把要发送的json作为字符串传入body即可

public static String sendHttpPost(String url, String body) throws Exception {
CloseableHttpClient httpClient = HttpClients.createDefault();
HttpPost httpPost = new HttpPost(url);
httpPost.addHeader("Content-Type

留言与评论(共有 0 条评论)
   
验证码:
Top