Java HTML parsers modify page
Is it possible to use some kind of an HTML parser with which I will choose information under which tag I want to display, and just clear all the rest?
I tried using Jsoup. Developing for android. durig selection my application crashes due to 'outofmemmoryerror'
You can extract portion of tag using JSoup and can separate it out
For Example :
String html = "<p>An <a href='http://example.com/'><b>example</b></a> link.</p>";
Document doc = Jsoup.parse(html);
Element link = doc.select("a").first();
String text = doc.body().text(); // "An example link" , and ignore the rest
精彩评论