One of the many nice features of iPhone is that Mobile Safari will auto-detect any phone numbers on a web page and turn them into links. Very handy. Much better than remembering the number as you switch from the browser to the phone.
However, this auto-detection is a bit overzealous. In addition to phone numbers, I’ve seen it link date ranges (1978-2008), specific dates (3/9/2009), and—for us baseball stat geeks—offensive rate statistics (.312/.418/.515… and I’ll send a BatchBlue tee shirt to the first person to identify that sweet career line).
Tonight, I was building a page and tested it in iPhone. It incorrectly linked some dates. This was problematic because in that specific section, I had all anchors set to
display: block;. So, adding these extra links broke the design.
I could have added some extraneous markup and worked around it, but I was curious if there was a way to turn off this auto-detection. Turns out, there is.
<head>, add this line:
<meta name="format-detection" content="telephone=no" />
That will turn off ALL phone number auto-detection on that page. Enjoy!