Reputation: 41
I have an application running in android 2.3.6 (news reader app). I use web views with custom html to present article detail. The encoding is utf-8 and I use the load data function to show content.
The problem is that in android 4.0 emulator (and devices) the encoding breaks down. I have tried using base64 encoding, which fixes the problem for android 4.0 but breaks down the encoding in 2.3.6.
Does anyone have any suggestions? Thanks in advance.
ps: the app is in greek. I do not see any escaped characters, just meaningless symbols
Upvotes: 3
Views: 1481
Reputation: 1458
I found a solution for Russian. Android WebView LoadData - Turkish Chars
if you have htmlsource:
webview.loadDataWithBaseURL("", source, "text/html", "UTF-8", null);
or
webview.loadDataWithBaseURL(url, "", "text/html", "UTF-8", null);
Maybe it'll help you too.
Upvotes: 6