Android studio 中 String 轉 JSON
try {
JSONObject result = new JSONObject(str); // String 轉 JSONObject
result.get("字段名"); // 獲取值
} catch (JSONException e) {
e.printStackTrace();
}
try {
JSONObject result = new JSONObject(str); // String 轉 JSONObject
result.get("字段名"); // 獲取值
} catch (JSONException e) {
e.printStackTrace();
}