Hi Experts,
i need to post image on server by http post with some parameters, here
is a piece of code i am trying:
List <NameValuePair> nvps = new ArrayList <NameValuePair>();
nvps.add(new BasicNameValuePair("message[content]","abc"));
nvps.add(new BasicNameValuePair("message[image]","?")); // here i need
image buffer
here is the buffer but this is writing directly to my connection
output stream which i dont have in above httppost,
InputStream is = this.content_resolver.openInputStream(imagefile);
while( (bytesRead = is.read(buffer)) > 0) {
wr.write(buffer,0,bytesRead);
wr.flush();
}
any solution?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---