I have issue with spanish characters in java string. I have a content
RSS feed and when i try to transform it to java object using
InputStreamReader, I get outputs like "cómo" which should be "cómo".
This is happening with other spanish characters like
á = á é = é í = à ó = ó ú = ú
and more..
How can I convert these characters to proper spanish characters?
Here is how my InputStreamReader looks like:
Reader reader = new BufferedReader(new InputStreamReader(is, "UTF-8"),
1024);
I tried doing my own method like this:
public static String fixSpanish(String s)
{
s = s.replaceAll("á", "á");
s = s.replaceAll("é", "é");
s = s.replaceAll("Ã", "í");
s = s.replaceAll("ó", "ó");
s = s.replaceAll("ú", "ú");
Log.d(TAG, s);
return s;
}
But, this didn't work. None of search combinations are ever found.
Any ideas?
Thanks in advance
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en