Mobile Developer

Monday, March 3, 2014

One on android parse json data contains html tags and style display problems


webview tag android html data
I received the label as well as the style of json data contains html because there are "#" symbol of class, cause I can not
 webview.loadDataWithBaseURL (null, contentHtml, "text / html", "utf-8", null); 


Turn out well contains

likeI use webview not?<-! Main posts under Banner (D4) -><-! Posts under the main text (D5) ->
Reply:
json data is this:

 {"content": "

\ r \ n \ t \ r \ n2013 \ u5e7410 \ u670823 \ u65e5 \ r \ n <\ / p> "}


Find Great God help! Of much embarrassed
Reply:
Do not sink ah! ~
Reply:
First data encoding server, the client re-solution
Reply:
reference to the third floor lyright reply:
first data encoding server, the client re-solution



Thank you! While waiting for a good while yet been resolved:
As long as the data returned Html.fromHtml html look like.
 webview.loadDataWithBaseURL (null, Html.fromHtml (contentHtml) + "", "text / html", "utf-8", null); 
ou at 11:02 PM
Share

No comments:

Post a Comment

‹
›
Home
View web version
Powered by Blogger.