You'll want to do:
result= new String( Base64.decode( text, Base64.DEFAULT ), "ISO-8859-5" );
Please change ISO-8859-5
to suit your needs, but this should be standard cyrillic charset encoding.
문제
I have a database which is encoded with Base64. I am getting data from that DB and i use it in my android layouts. When there is Cyrillic encrypted text, all i am getting is a question mark in a rhombus. I am using standard function to decode and it is working properly with Latin characters.
public String decrypt(String text)
{
String result;
result = new String( Base64.decode( text, Base64.NO_WRAP ) );
return result;
}
What should i change to get the Cyrillic output?
해결책
You'll want to do:
result= new String( Base64.decode( text, Base64.DEFAULT ), "ISO-8859-5" );
Please change ISO-8859-5
to suit your needs, but this should be standard cyrillic charset encoding.