
Phone numbers in email?
Hi there!
So, we have two emails. Exactly the same- but different phone numbers.
I look at the test on my gmail android app (and in my gmail desktop) and in one the phone number is recognized by my device and it turns blue and is underlined. In the other, is it still clickable to make the call, however its just the regular colour that we designed it to be in the email.
Any idea why one gets recognized and the other doesnt?
The phone number that doesnt get recognized is: 1 877 XXX-XXXX
The phone number that does is: 1 800 XXX-XXXX
Do you think its because its a 1 800 number that its recognized?
However, if we fully hyphenate: 1-877-XXX-XXXX it then gets recognized.
Sidenote: is there a way to have it not get recognized and stay the same as the design incase client wants that? Would this impact desktop mobile and webmail or just some email clients?
Thanks!
I add the below to my css as well as doing the iPhone format detection...
Then
I'm confused, where's your <a> tag within <span class="black"> tags?
It generates an a tag which is why it's hard to stop the colour and underline.
Read more here: Gmail links
Cool, thanks!
Weird that it's only picking up on some, iPhone will turn anything into a phone number, including reference numbers, order numbers, company numbers. It's really annoying.
You can try adding
<meta name="format-detection" content="telephone=no">
to your <head> to stop it detecting the phone if that's what you're after. I've not tested this with gmail app but it might work.Or put a link around it
<a href="tel:1800xxxxxxx"><span style="text-decoration:none; color:#123456;">1 800 xxx-xxxx</span></a>
and style it how you want, be that as a link or to look like the rest of the text.I'm guessing any meta tags, or styles in the head will be ignored by the Android Gmail App.
I would go with Mark's advice and wrap them in <a> tag with the tel: prefix and then style away.
I've had that issue where the phone number is populated dynamically, and some numbers had dashes and some didn't. That was tricky. ExactTarget's AMPscript came to the rescue with the Replace() function.
Actually my method does work. I have a tonne of phone numbers and dates in my emails and my method works perfectly :)
Did some testing, and Becs, please chime in.
<head>
meta name="format-detection" content="telephone=no"
.red a {text-decoration: none;color:#ff0000;}
</head>
<span class="red">800-123-6890</span>
<span class="red"><a href="tel:8001236890">800-123-6890</a></span>
800-123-6890
The results on my personal phone (Android ) using the Gmail App, and looking at Litmus results is:
first number is black and is not clickable
second number is default blue, underlined, and is a clickable link
third is black and not clickable
Maybe I did something wrong, but I don't see where any of the head content is being applied.
Is the number prefixed with "tel:" or not?
Nope
Could it be that 1 800 are toll free numberrs but 877 aren't?
877 is toll free too, so is 866 but im thinking maybe its more widely known that 800 is and so thats why its being recognized?
Weird!
Ok well, I'd use the tel URI as described here to test further:
http://tools.ietf.org/html/rfc3966#page-12