![](https://img-blog.csdnimg.cn/20201014180756780.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
接口
文章平均质量分 77
g_blue_wind
这个作者很懒,什么都没留下…
展开
-
利用接口向服务器端传递数据
1、方法一 (1)、result = HttpRequest.sendGet(url+pds.getString("eId"), null); //向服务器端传递数据获取返回值 url为接口地址 JSONObject newresult = JSONObject.fromObject(result); int errorCode = (int)newresult.getInt("erro原创 2016-07-13 11:43:15 · 3833 阅读 · 0 评论 -
利用接口发送文件
//向向网格化平台发送图片 public static void main(String[] args) throws Exception{ String response=""; PostMethod postMethod = new PostMethod("http://172.16.2.79:8080/zdxqcg/api/workflow/file"); HttpC原创 2016-07-12 17:59:10 · 3568 阅读 · 0 评论 -
httpClient
1. 读取网页(HTTP/HTTPS)内容 下面是我们给出的一个简单的例子用来访问某个页面 /* * Created on 2003-12-14 by Liudong */ package http.demo; import java.io.IOException; import org.apache.commons.httpclient.*; import org.ap转载 2016-07-12 11:34:36 · 253 阅读 · 0 评论 -
JAVA跨域数据提交
1、上传文件 (1)、图片 public void postFile(String imgpath,String fileuuid) throws Exception{ String response=""; Properties pro = GetProperties.getKey("wgh.properties"); String fileurl = pro.getProperty(原创 2017-03-22 10:37:09 · 623 阅读 · 0 评论