简体   繁体   中英

How to call 2 digit phone number in IOS 6 7 8 using tel links

I wonder why 2 digit phone number won't open phone app after tapping "call"

<a href="tel:555">555</a> // shows alert, tap on call opens phone app

<a href="tel:55">55</a>  // shows alert, tap on call won't open app

If this isn't possible using the tel scheme, then Apple's implementation doesn't conform to RFC2806 (which they reference in their documentation for Phone Links ), which states:

It should also be noted that implementations MUST NOT assume that telephone numbers have a maximum, minimum or fixed length, or that they would always begin with a certain number. Implementors are encouraged to familiarize themselves with the international standards.

I'd file a bug.

I don't think 2 digit phone numbers are functional numbers. Apple does not allow you to call numbers shorter than 3 digits.

According to spec, a valid telephone number should consist of the first digit of the area code being between 2 and 9, followed by at least 2 digits. Therefore, the smallest valid telephone number is at least 3 digits long.

If your attempting to do something like dial a number, and then dial an extension you can define a pause with p like this:

tel:234p55

w can also be used to specify a wait-for-dialtone.


I do not know if this will work or not but you may be able to dial a 2 digit number using phone-context

<a href="tel:55;phone-context=+234">55</a>

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM