1

I just discovered the html 5 way to make a link to a phone number like this:

<a href="tel:12345"

Works great on a mobile phone, but gives an error on a desktop browser like firefox. How to improve the user experience for the desktop user?


Update:

This question is already answered in this SO question. There I added my new insights as an answer.

Roland
  • 3,391
  • 5
  • 32
  • 63
  • I think it's better to distinguish such a links using `a[href^="tel"]` in CSS, read more [here](https://stackoverflow.com/a/17391097/4344976) – Muhammad Musavi May 04 '19 at 10:05

1 Answers1

0

Seems like no application assigned to tel: url on desktop. One of variants you can parse navigator.appVersion javascript object to replace tel: link with skype: for example. Take a look What is the best way to detect a mobile device in jQuery?

  • thanks. I will look for a way to detect if a feature like tel: is not supported, then replace the anchor with a plain text field (span). I think there are easy ways to detect features. – Roland Sep 15 '17 at 17:36