Here is my code snippet:
HttpClient client = new DefaultHttpClient();
String urlStr = FolderManager.ApplicationUnderTestUrl();
HttpPost post = new HttpPost(urlStr);
List<BasicNameValuePair> nameValuePairs = new ArrayList<BasicNameValuePair>(1);
if ((paramName != null ) && (paramVal != null))
{
for (int i = 0; i < paramName.length; i++)
{
nameValuePairs.add(new BasicNameValuePair(paramName[i], paramVal[i]));
}
}
post.setEntity(new UrlEncodedFormEntity(nameValuePairs ,"UTF-8"));
HttpResponse response = client.execute(post);
BufferedReader rd = new BufferedReader(new InputStreamReader(response.getEntity().getContent()));
The above code adds some + (plus) signs to my parameter values wherever a ' '(space) is encountered. How can I avoid this?