when I click on links in my app, they open in the same webview. I want them to open in an external browser.
I did this:
myWebView.setWebViewClient(new WebViewClient()
{
@Override
public boolean shouldOverrideUrlLoading(WebView view, String url) {
return false;
}
});
returning false makes it load within the same webview, and returning “true” makes nothing happen when a link is clicked.
I looked at other questions but it seems that everyone else has the exact opposite problem. (they want links to load in their app)
what am I doing wrong?
In your
WebViewClientThat way it opens a new browser window the same way any other app would.