开发者

Android WebView LoadData - Turkish Chars

开发者 https://www.devze.com 2023-04-03 17:42 出处:网络
How can I show turkish chars (ş, ğ, ü ...) in webview as loadData? My webview is:mWebView.loadData(detailsHtml, \"text/html\", \"UTF-8\");

How can I show turkish chars (ş, ğ, ü ...) in webview as loadData?

My webview is: mWebView.loadData(detailsHtml, "text/html", "UTF-8");

t开发者_高级运维hanks.


webView.loadData(htmlStr, "text/html; charset=utf-8", null);

This line of code saved me to deal with turkish character set. I hope it helps others too.


Try this code

mWebView.loadDataWithBaseURL(null,"ş, ğ, ü ","text/html", "UTF-8", null);
0

精彩评论

暂无评论...
验证码 换一张
取 消