Android WebView tel: links show web page not found
OK so I solved the issue I think. I just needed to separate the URL overrides as follows:
public boolean shouldOverrideUrlLoading(WebView view, String url) {
if (url.startsWith("tel:")) {
Intent intent = new Intent(Intent.ACTION_DIAL, Uri.parse(url));
startActivity(intent);
view.reload();
return true;
}
view.loadUrl(url);
return true;
}
Now my regular links work as well as the tel links. I can also add in there for geo: links if I need to and it will not give me the issue that I was having before to open up maps on the phone.
Clicking on email address loads it as a webpage as well on webview
Try with using return true;
in shouldOverrideUrlLoading()
method. :)
Related Topics
Sniffing/Logging Your Own Android Bluetooth Traffic
Android Broadcast Receiver Bluetooth Events Catching
Intent.Resolveactivity Returns Null in API 30
Android Java Lang Runtimeexception Fail to Connect to Camera Service
Linkedlist Put into Intent Extra Gets Recast to Arraylist When Retrieving in Next Activity
Which Correct Flag of Autoconnect in Connectgatt of Ble
How to Solve Execution Failed for Task ':App:Compileflutterbuilddebug'
Need an Example About Recyclerview.Adapter.Notifyitemchanged(Int Position, Object Payload)
How to Transfer an Image from Its Url to the Sd Card
Android Facebook Sdk 3.0 Gives "Remote_App_Id Does Not Match Stored Id" While Logging In
Android: Change Shape Color in Runtime
Disable the Notification Panel from Being Pulled Down
Lazy Download Images into Gridview
Only Load Layout When Firebase Calls Are Complete
Android - How to Pass Hashmap<String,String> Between Activities