I’m trying to send GPS data over http request.
The problem is that the GPS data is in double format and nameValuePair.add(new BasicNameValuePair(String, String)
will not allow double values.
How do I send double values or convert the double to a string?
Thanks,
httpclient client = new defaulthttpclient();
httppost post = new httppost("web address");
post.setEntity(new UrlencodedFormEntity(nameValuePairs));
httpresponse response = client.execute(post);
you may need to use two nameValuePairs to send latitude and longitude separately: