jsonObject.set("mobilePhoneNumbe", mobilePhoneNumbe);
String mob=jsonObject.toString();
String base = "https://api.leancloud.cn/1.1/requestMobilePhoneVerify";
try {
String s=httpsUtil.post(base,mob);
}
调用的方法为
public static String post(String url,String data)
throws MalformedURLException, IOException {
byte[] d = null;
HttpsURLConnection conn = getConnection(url);
conn.setRequestMethod("POST");
conn.setDoOutput(true);
conn.setRequestProperty("Content-Type", "application/json");
conn.setRequestProperty("Content-Length", data.length() + "");
OutputStream out = conn.getOutputStream();
out.write(data.getBytes("utf-8"));
out.flush();
out.close();
if (conn.getResponseCode() == 200) {
d = readInputStream(conn.getInputStream());
return new String(d, "utf-8");
} else {
return conn.getResponseMessage();
}
}
请问哪里的问题