3

Sometimes the rendered display of an HTML email body is incorrect. Eg:

  • OC gmail is rendered correct
  • Mobile app gmail is rendered correct
  • Mobile web gmail is rendered incorrect

This problem occurred only on mobile web gmail.

HTML body has a <table> tag. In the incorrect case, this table tag is broken with part of <div> tag.

I tried several times in mobile web gmail. The first email displayed correctly but the second email displayed incorrectly.

My question is: why this happen? How do I fix it?

Ted Goas
  • 7,051
  • 1
  • 35
  • 42
Dongkwon Lee
  • 203
  • 1
  • 9

1 Answers1

2

It's been a while since this question was asked, but I ran across the same problem myself now in 2022.

First of course I looked for the error on our end and rebuilt html/css. However, I could not find the error, it seemed to happen completely randomly.

A completely identical email sometimes looked perfectly fine, sometimes it was rendered completely broken (this can also be seen by looking at the HTML code: clean code turned into a completely chopped up array of HTML code that was definitely not ours (especially early terminated HTML tables, heaps of "empty" snippets, etc).

Then, by chance, I noticed that this phenomenon does NOT occur if I permanently delete similar emails that are ALREADY in the trash (sic!).

I have been able to narrow down the problem even further: apparently GMail bundles messages, from the same domain and with the same subject line, even if they are in the trash (however, you do NOT see this directly in the inbox, but only when you are on the (broken) email in question and refresh by dragging down (mobile) - all of a sudden, all the trash messages are additionally visible at the top of this message).

I was able to fix the problem by always writing value into the subject line that does not match any other email. This avoids the incorrect bundling and the mails look flawless again.

Cost me a lot of nerves and half a day's work - maybe I can save this for someone with my contribution.

Grimm
  • 690
  • 8
  • 17