0

I'm creating an email template and, when testing things on Email on Acid, the Samsung Mail version converts all dates and the word "Today" into an hyperlink. Obviously none of these are actually coded as one.

Any ideas on how to prevent this?

dawn
  • 1,327
  • 6
  • 19
  • 39
  • For the person that wants to delete my question, SO is the right place since it's a question about code, HTML, not "settings". Also, they closed this same question in SuperUser, as suggested... – dawn Feb 09 '21 at 15:35
  • This probably belongs on [android.se] as this is more likely a problem with the Samsung Mail application on their Android phones. – Mokubai Feb 09 '21 at 15:42
  • @Mokubai no, it has to do with HTML and CSS. – dawn Feb 09 '21 at 16:02
  • I just know that this is a Samsung-ism and is prevalent in their slightly badly written applications. Their messages app has the same bad behaviour of converting things to calendar links when they really shouldn't. If something is being converted when it shouldn't then that is an application problem, not necessarily a problem with your "code". – Mokubai Feb 09 '21 at 16:06
  • The real question would be what does someone not using that application see? Do they get what you want, or do they get the "smart" version as shown by Samsung Email? That would tell you if the problem is your template or the receiving application. – Mokubai Feb 09 '21 at 16:08
  • @Mokubai I need help with HTML tables, CSS, tricks on this. I understand it's not my fault, but since I didn't found this question here, I thought about asking it in case someone has a trick for it and to help others. One solution is to `text-underline: none` for example. – dawn Feb 09 '21 at 16:25
  • `text-decoration: none` not `underline` – dawn Feb 09 '21 at 21:24
  • 1
    I am with Dawn on this. Questions like this get deleted/closed because some admins don't understand this is HTML emails. It required inline CSS to fix and nothing at app level can fix these things. – Syfer Feb 09 '21 at 22:21
  • 1
    In a perfect world, the app would get updated. In the meantime, we need a hack to get around it. – Nathan Feb 10 '21 at 00:52

1 Answers1

2

Try adding this to your CSS. This is the most common styling override for that very issue on Samsung Mail.

#MessageViewBody a {
  color: inherit;
  text-decoration: none;
  font-size: inherit;
  font-family: inherit;
  font-weight: inherit;
  line-height: inherit;
}
gj-wes
  • 912
  • 5
  • 9
  • 1
    It's worth noting that this doesn't actually remove the automatic linking, it just removes the styling. To break the automatic linking completely, you have to trick the system - see https://stackoverflow.com/questions/8395004/is-there-a-way-to-disable-email-engines-from-automatically-hyperlinking-a-url/34535152v – Nathan Feb 10 '21 at 00:59