Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Disable telephone number detection on iPad desktop web links?

Tags:

html

ipad

I'm developing a web application that will be launched from a desktop icon on an iPad as a full-screen application. The Apple documentation on phone links recommends using this meta tag:

<meta name="format-detection" conten ="telephone=no">

However, this does not appear to work. Is there any other HTML/CSS/JavaScript mechanism to control this behaviour?

The random injection of anchor tags is causing me a lot of CSS bugs.

Workaround

One hack I've found to work is to inject special space characters, but the thought of transforming all my data on output does not fill me with joy. Such characters bring their own issues to the table. Doing this will be further complicated by AJAX and JavaScript transformations.

Reproducing

Steps to reproduce:

  1. Open the page on iPad Safari.
  2. Use the Add to Home Screen bookmark function.
  3. Launch the Home Screen icon.

Sample page:

<!DOCTYPE html>
<html>
<head>
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name = "format-detection" content = "telephone=no">
<title>Telephone detect</title>
</head>
<body>
expected:
<a href="tel:1555555">1555555</a>
<br />
bad: 1555555
<br />
bad: &#x31;&#x35;&#x35;&#x35;&#x35;&#x35;&#x35;
<br />
inconvenient: 1&#xFEFF;555555
</body>
</html>

Notes

This question seems to be related, but it lacks detail and I'm not sure if the behaviour is identical on the iPhone. This is a web application and has no native component. iPad version 3.2.2.

like image 934
McDowell Avatar asked Nov 24 '10 15:11

McDowell


People also ask

How do I remove shared links from my IPAD screen?

Remove shared links from Shared with YouTouch and hold the preview image of the link you want to remove. Tap Remove Link.


1 Answers

The meta tag works for me in asp.net. My guess is that it did not work for the OP because the HTML is not well formed. Non-IE, Mozilla browsers have issues with malformed XML/Html. Change

<meta name = "format-detection" content = "telephone=no">

to

<meta name = "format-detection" content = "telephone=no" />
like image 125
P.Brian.Mackey Avatar answered Sep 21 '22 01:09

P.Brian.Mackey