I list a phone number on my website at the moment and it is currently linked to "tel:myphonenumber"... how can I remove this a href unless the site is loaded on a mobile?
Asked
Active
Viewed 2,039 times
2
-
1possible duplicate of [How can I make an only active on mobile devices?](http://stackoverflow.com/questions/13409089/how-can-i-make-an-a-href-only-active-on-mobile-devices) – John Conde Dec 05 '12 at 00:53
-
seems to be the same sort of question. how can I tell if the vcard is actually working? I don't know how to clear cache on an iphone to test with and without the div's... – Reece Dec 05 '12 at 01:17
-
I would think some JavaScript could accomplish this. – Yamaha32088 Dec 05 '12 at 01:26
3 Answers
0
This has already been answered here How can I make an <a href> only active on mobile devices?
You should use microdata. As Mobile phones will recognize it, and it won't affect normal web browsers.
<div class="vcard">
<div class="tel">
12345555555
</div>
</div>

Community
- 1
- 1

Rami Alloush
- 2,308
- 2
- 27
- 33
0
HTML
<td><a href="tel:888888">888888</a></td>
CSS
@media screen and (min-width: 1224px) { a[href*="tel:"] { pointer-events: none; } }

Ashutosh Jha
- 15,451
- 11
- 52
- 85
-2
Unfortunately there is no way to accomplish that.

Brian Cray
- 1,277
- 1
- 7
- 19
-
As you can see [here](http://stackoverflow.com/questions/13409089/how-can-i-make-an-a-href-only-active-on-mobile-devices), there is a way... – poplitea Dec 05 '12 at 01:24
-