String urlParameters = "login=test&password=te&ff";
I have a String urlParams, & - is part of the password, how to make it escaped, thus not be recognized as a separator?
String urlParameters = "login=test&password=te&ff";
I have a String urlParams, & - is part of the password, how to make it escaped, thus not be recognized as a separator?
Use a URL Encoder on each of the components: http://docs.oracle.com/javase/7/docs/api/java/net/URLEncoder.html
Encode your password using URLEcoder#encode with utf-8
String urlParameters = "login=test&password="+
URLEncoder.encode("te&ff", "UTF-8");