2011-09-08 54 views
3

如何在webview中以loadData方式顯示土耳其字符(?,?,...)?Android WebView LoadData - 土耳其語字符

我的網頁流量是:mWebView.loadData(detailsHtml, "text/html", "UTF-8");

感謝。

+0

http://code.google.com/p/android/issues/detail?id=3552 –

+2

我發現它, 如果你有htmlsource: webview.loadDataWithBaseURL( 「」,源,「text/html的「,」UTF-8「,null);其他: webview.loadDataWithBaseURL(url,「」,「text/html」,「UTF-8」,null); –

+0

你可以試試這個。它的工作對我的項目... [此處輸入鏈接的描述] [1] [1]:http://stackoverflow.com/questions/11827628/after-webview-used-custom-fonts – user1579047

回答

0

嘗試此代碼

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

webView.loadData(htmlStr, 「text/html的;字符集= UTF-8」,NULL);

這行代碼保存了我來處理土耳其字符集。我希望它也能幫助別人。