java推送数据,java代理post提交数据(二)

2014-11-24 09:39:51 · 作者: · 浏览: 1
er("homepageurl", "http://");
method.setParameter("pic", "p5.gif");
method.setParameter("validatecode", validate);
method.setParameter("content", connect);

// if (todo) {
int code = httpClient.executeMethod(method);

// String Stringresponse = new String(method.getResponseBodyAsString().getBytes("8859_1"));
// 打印返回的信息
// System.out.println(Stringresponse);
// }

method.releaseConnection();

// System.out.println(iag.getHeight());
// System.out.println(iag.getWidth());
// //背景 颜色
// intBgColor = iag.getRGB(38, 0);
// System.out.println("intBgColor=" + intBgColor);
//
//
// intBgColor = iag.getRGB(0, 0);
// System.out.println("intBgColor=" + intBgColor);
} catch (Exception e) {

// 发生网络异常
e.printStackTrace();
} finally {}

// 释放连接 getMethod.releaseConnection(); }
getMethod.releaseConnection();
}
}