HTML5 Emails - iOS - Disable Word Sentence?

I'm not sure I was looking for the right thing, but in the HTML5 email I am sending I have the following line: -

<h3>IS THAT THE SOUND OF SLEIGH BELLS?</h3> 

And on my iPhone 7, Sleigh Bells is an interactive link that shows offers like the ones below.

I tried wrapping h3 with span tags, I added the following CSS: -

 [x-apple-data-detectors] { color: inherit !important; text-decoration: none !important; font-size: inherit !important; font-family: inherit !important; font-weight: inherit !important; line-height: inherit !important; } 

That only stylizes the text so that it does not look like a link, but it is still clickable.

I also tried adding the following line: -

 <tag autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/> 

But so far I have not been able to find a way to make this word / phrase not clickable, does anyone have any ideas?

enter image description here

+5
source share
2 answers

According to my comment above (I did not test this, but was confirmed by working OP) by adding the following CSS style so that this element works to disable link behavior on iOS devices.

pointer-events: none;

Perhaps this needs to be added using the CSS rules defined in iOS mentioned in the question:

[x-apple-data-detectors]

+4
source

I know that this answer has already been resolved, but I wanted to offer a fix for other email clients who have problems with data detectors, Gmail and Windows 10 Mail.

In Gmail, this phone number gets a blue backlight and changes to blue, even with an Apple Data detector installed. In addition, Windows 10 Mail places a black dashed line under the word Monday:

 800-422-4234 Monday through Friday, 8 am to 9 pm Eastern Time. 

I added &zwnj; , non-printable character in the number 800 and in the word Monday. I put &zwnj; between Mo , because Mon Windows 10 Mail recognizes Mon as the abbreviation for Monday and emphasizes Mon.

 800-422-42&zwnj;34 Mo&zwnj;nday through Friday, 8 am to 9 pm Eastern Time. 

This fixes data discovery using Gmail and fixes the Monday issue in Windows 10 Mail, but then underlines the word Friday . So I did the same:

 800-422-42&zwnj;34 Mo&zwnj;nday through Fr&zwnj;iday, 8 am to 9 pm Eastern Time. 

This fixes the data discovery issue in all the major email clients I tested. Here's how I use Apple Data Discovery:

 <style> [x-apple-data-detectors] { color: inherit !important; text-decoration: none !important; font-size: inherit !important; font-family: inherit !important; font-weight: inherit !important; line-height: inherit !important; } </style> 

I hope this helps other people face data discovery issues with phone numbers and dates.

Good luck.

+1
source

Source: https://habr.com/ru/post/1274032/


All Articles