tags:

views:

61

answers:

1

friends,

i am trying to upload file to php server using following tutorial http://getablogger.blogspot.com/2008/01/android-how-to-post-file-to-php-server.html

i dont know how to add parameters like

userid="12312";sessionid="234" in it.

any one guide me how to achieve this?

any help would be appreciated.

A: 

over the internet you will find a lot of examples

Executing a HTTP POST Request with HttpClient

how to add parameters? you must have something like.

// Add your data  
List<NameValuePair> nameValuePairs = new ArrayList<NameValuePair>(2);  
nameValuePairs.add(new BasicNameValuePair("userid", "12312"));  
nameValuePairs.add(new BasicNameValuePair("sessionid", "234"));  
httppost.setEntity(new UrlEncodedFormEntity(nameValuePairs));  
Jorgesys