I am trying to extract small portion from webpage and load into webview
I have tried following solution given in the link,But it did not work
Display a part of the webpage on the webview android
Extracting data using getElementsByClass("darewod")
htmlDocument = Jsoup.connect(htmlPageUrl).get();
element = htmlDocument.getElementsByClass("darewod");
String html = element.toString();
String mime = "text/html";
String encoding = "utf-8";
I have tried the following two methods to load to webview but it seems not working,Its just printing HTML on UI
wv1.loadDataWithBaseURL(null, html, "text/html", "utf-8", null);
wv1.loadData(html, "text/html", null);
Can you please tell me if i am missing anything here?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…