public static void main(String[] args) throws UnsupportedEncodingException { String before = "£2.00 per month³"; String encoded = URLEncoder.encode(before, "UTF-8"); String decoded = URLDecoder.decode(encoded, "UTF-8"); System.out.println(encoded); System.out.println(decoded); }
At the output, I get:
%C2%A32.00+per+month%C2%B3 £2.00 per month³
Are you sure that %A32.00%20per%20month%B3 correct?
source share