javascript - How to have Android webview open links that are target “_blank” in default browser -


how have android webview open links target “_blank” in default browser , tried following code still show links webview , 1 have solution ?

 public boolean shouldoverrideurlloading(webview view, string url) {             string myalternativeurl = "http://example.com";               if (!url.equals(myalternativeurl)) {                   {                     intent = new intent(intent.action_view);                     i.setdata(uri.parse("http://example.com"));                     startactivity(i);                     }                 return true;               } else {             view.loadurl(url);             return true;         }         } 


Comments

Popular posts from this blog

commonjs - How to write a typescript definition file for a node module that exports a function? -

openid - Okta: Failed to get authorization code through API call -

ios - Change Storyboard View using Seague -