TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Ask HN: How do you handle images in email templates?

4 点作者 rob001超过 6 年前
There doesn&#x27;t seem to be a recommended way of handling images that I can see, with three options being:<p>1. Linked images 2. Cid images (images are attached) 3. Base64 encoded images<p>My gut says to stick to linked images for simplicity and ensure the image title tags are descriptive. At work we use cid images as they seem to show up more often during testing.<p>Any recommendations?

2 条评论

chatmasta超过 6 年前
This is not my area of expertise, but I do know that for a reader in Gmail, the behavior is always the same: Google downloads the image and serves it to the user from their own servers (designed to beat tracking pixels).<p>You might find this SendGrid post [0] helpful, but probably you&#x27;ve seen it already.<p>[0] <a href="https:&#x2F;&#x2F;sendgrid.com&#x2F;blog&#x2F;embedding-images-emails-facts&#x2F;" rel="nofollow">https:&#x2F;&#x2F;sendgrid.com&#x2F;blog&#x2F;embedding-images-emails-facts&#x2F;</a>
SmileyJames超过 6 年前
<a href="https:&#x2F;&#x2F;mjml.io&#x2F;" rel="nofollow">https:&#x2F;&#x2F;mjml.io&#x2F;</a> may help you with a lot of email html headaches. I suggest option 1 - linked images, worked for me.