Skip to content

Latest commit

 

History

History
20 lines (12 loc) · 646 Bytes

README.rdoc

File metadata and controls

20 lines (12 loc) · 646 Bytes

DESCRIPTION

Need to post an image to a server? Or just send a plain POST request in a snap? This simple framework is to help.

USAGE

First you have to set up request parameters, they can be either string of file type, see below:

List<PostParameter> params = new ArrayList<PostParameter>();
params.add(new PostParameter<String>("fullname", "John Doe"));
params.add(new PostParameter<File>("headshot", new File(Environment.getExternalStorageDirectory() + "/shot.png"));

Then you just send the params to server by calling this:

MultipartPost post = new MultipartPost(params);
post.send("http://www.yourhost.com");

That’s all.