Please help me to figure out my question answer i tried to find so many times on Google but i cant able to find its solution.
First i am getting this exception
java.lang.IllegalArgumentException: Illegal character in query at index 130
than after i add this code in my code.
String restUrl = URLEncoder.encode(url, "UTF-8");
HttpGet httpget = new HttpGet(restUrl);
then i am getting this exception
java.lang.IllegalStateException: Target host must not be null, or set in parameters.
Please help me solve out from this exception. Please.
Here is my code.