通用post方法

2021-07-25 00:17:51 字數 429 閱讀 4401

/**

* 向指定 url 傳送post方法的請求

* * @param url

*            傳送請求的 url

* @param param

*            請求引數,請求引數應該是 name1=value1&name2=value2 的形式。

* @return 所代表遠端資源的響應結果

*/public static string sendpost(string url, jsonobject param)

} catch (exception e)

//使用finally塊來關閉輸出流、輸入流

finally

}catch(ioexception ex)

}return result.tostring();

}    

通用 排序 方法

public class sortlist catch nosuchmethodexception ne catch illegalacces ception ie catch invocationtargetexception it return ret 在興趣的驅動下,寫乙個免費的東西,有欣喜,...

通用 排序 方法

public class sortlist catch nosuchmethodexception ne catch illegalacces ception ie catch invocationtargetexception it return ret 在興趣的驅動下,寫乙個免費的東西,有欣喜,...

通用方法3

region 獲取url字串引數,返回引數值字串 獲取url字串引數,返回引數值字串 引數名稱 url字串 public static string getquerystring string name,string url return endregion region 字串加密 public s...