1

I am developing a Client using HttpClient in Java to access a REST Application. In this i want to pass two parameters name(value="Kiran") and address(Value="5th Corner/Road") as path parameters .

Sample url:-http://localhost:port/rest/name/Kiran/address/5th Corner/Road

But as address contains "/" as value, its not taking the actual value. Is there a way to handle "/" while accessing REST applications from Java.

Any help is appreciated.

Manu
  • 1,379
  • 6
  • 24
  • 53

1 Answers1

2

Use java.net.URLEncoder to encode the query parameters.