Code example for BasicNameValuePair

0
		attach(a);
	} 
 
	private List<NameValuePair> prepareUploadData(String userId, String friendId, String friendMessage) {
		List<NameValuePair> data = new ArrayList<NameValuePair>();
		data.add(new BasicNameValuePair("users_id", userId));
		data.add(new BasicNameValuePair("friend_id", friendId));
		data.add(new BasicNameValuePair("friend_message", friendMessage));
		return data;
	} 
 
	@Override 
	protected Boolean doInBackground(String... ids) {
		List<NameValuePair> data = prepareUploadData(ids[0], ids[1], ids[2]);
		JSONObject json = JsonHelper.getJsonObjectFromUrlWithData(SEND_REQUEST_URL, data);
		try { 
			if (json.getString("result").equals("success")) {
				return true; 
			} 
		} 
		catch (JSONException e) {