Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to get rid of "Show trimmed content" in GMail HTML emails?

I send a lot of HTML emails. The problem with GMail is, if there are more than one emails with the same subject, it hides some similar content and shows a "..." to show the "trimmed content". This screws up with my formatting.

If changing the subject is not an option, is there is any way to avoid this behaviour?

Edit: I should clarify that I programmatically send emails using Amazon SES from a php script. That is why I posted the question in Stack Overflow.

like image 849
Munim Avatar asked Jun 18 '12 07:06

Munim


People also ask

How do I get Gmail to not show trimmed content?

To avoid this, simply try inserting any randomly generated string inside your mail which will make your email messages different and will not let Gmail insert the Show Trimmed Content option. Just to confirm in case not obvious, this seems to work if the string is hidden as well.

Why is Gmail trimming my emails?

If you have ever noticed that your Campaigns are clipped when they reach your Subscribers's Inbox, it is because Gmail limits every Email with a size over 102 KB. When this happens, the reader receives a message saying “View entire message”, hidding the complete content of your Email piece.

How do I disable HTML in Gmail?

Click the "Plain Text" link on the formatting toolbar, which is directly on top of the Compose window, to turn off HTML formatting.

How to can I automatically expand the trimmed content in Gmail?

In Gmail, if there are more than one emails with the same subject, it hides some similar content and shows a "..." to show the "trimmed content": How to can I automatically expand the trimmed content in Gmail e-mails? Show activity on this post. There is no option to automatically show trimmed content in Gmail e-mails.

How to prevent Gmail from trimming email signatures?

The Gmail Bookmarklet will add a unique string to the email signature to prevent Gmail from trimming the content. The hex color code for the appended text is #444 so it will not be prominently displayed in Gmail. Amit Agarwal is a Google Developer Expert in Google Workspace and Google Apps Script.

How do I show trimmed content on the page?

I noticed that if you just hit the down arrow followed by Enter then the trimmed content is shown. Hitting the down arrow highlights the "..." reflecting the trimmed content, then hitting Enter has the same effect as clicking on it. Show activity on this post.

How do I prevent text from being trimmed?

If your name is Jim, try using Melvin, or Horatio. That should prevent the trimming, but it's not guaranteed. Just insert any unique content after the trimmed contents. That can be anything. Even you can make it invisible by adding it in very light color, like light gray.


2 Answers

I've just encountered this problem myself, and from my investigations it seems that GMail does indeed trim the content if it is similar to the preceding emails.

My solution is simply to insert the current time stamp at the end of every email:

[15:02:21 29/01/2013] End of message.

like image 150
dougwoodrow Avatar answered Oct 12 '22 13:10

dougwoodrow


To prevent this in HTML emails I'm adding two invisible unique elements: in the beginning and at the end of the mail. Like this:

...  <body> <!-- this ensures Gmail doesn't trim the email --> <span style="opacity: 0"> {{ randomness }} </span>  ...  <!-- this ensures Gmail doesn't trim the email --> <span style="opacity: 0"> {{ randomness }} </span> </body> 

{{ randomness }} is being replaced by my templating engine with the value of Date.now() (I'm using node.js, could be anything producing unique output)

like image 24
Troggy Avatar answered Oct 12 '22 12:10

Troggy