Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there a way to determine if browser can handle telephone links [duplicate]

I've read through other SO posts, but everyone seems to check the user agent, if its mobile, add href="tel:1234567890" else omit tel:. But what if I have Skype, Google Voice, or another application that CAN handle the links. Is there any way to determine this?

I don't know much about modernizer, but that didn't seem to have any properties to determine this capability. I'd rather not "turn off" desktop links just because I'm not sure, but at the same time IE opens up a blank page if it can't handle the scheme which I definitely can't have. Any thoughts or suggestions?

like image 799
MisterIsaak Avatar asked Jan 08 '14 22:01

MisterIsaak


People also ask

How do Tel links work?

Tel link is a telephone link used on websites. Simply said, it makes your phone number clickable. Therefore, whenever the customer wants to contact you, he/she can click on the link and connect with your customer support right away.

Which snippet of HTML when clicked make a phone call on a mobile device?

Href=tel: creates the call link. This tells the browser how to use the number. “Tel: 123-456-7890 “creates the HTML phone number. The number within the quotes is the number it will call.


1 Answers

No, you can't. Reason is because how the browser handles this is not your concern (from the browser's point of view).

My advise?

If you want such a link, then simply use it.

Competent browsers that do not know about tel: should ask the user what to do, for instance look for an app that handles that protocol in the store (MSIE windows / mobile, for instance) or plugin (firefox/chrome).

Edit: You could in theory do a check for mobile browsers and then fall back to checking known plugins (eg; skype), but this will definitely not cater to most of the case and will break down too soon to be feasible.

like image 64
Christian Avatar answered Oct 16 '22 20:10

Christian