java - How to predefine junction by JSoup parse? -


jsoup parses , displays list of links. how can track click on link, open new activity , start parsing link already?

here code:

protected void onpostexecute(void result) {         super.onpostexecute(result);           webview wv = (webview) findviewbyid(r.id.webview);         wv.loaddatawithbaseurl(null, html,"text/html", "utf-8", null);          wv.setwebviewclient(new webviewclient() {                  @suppresswarnings("deprecation")                 @override                 public boolean shouldoverrideurlloading(webview view, string url) {                     intent intent = new intent(mainactivity.this, trophactivity.class);                     startactivity(intent);                     return super.shouldoverrideurlloading(view, url);                 }             }); 

i solved problem myself. fact jsoup parsed links without domain (not absolute)

for( element urlelement : hrefs ) {                 urlelement.attr("href", urlelement.absurl("href"));             } 

Comments

Popular posts from this blog

ubuntu - PHP script to find files of certain extensions in a directory, returns populated array when run in browser, but empty array when run from terminal -

php - How can i create a user dashboard -

javascript - How to detect toggling of the fullscreen-toolbar in jQuery Mobile? -