我应该在电子邮件模板中使用 HTML 注释吗?
尝试查看向我的 html 电子邮件添加 HTML 注释是否有任何负面影响?
任何反馈都很棒。
谢谢
Trying to see if there are any negatives to adding HTML comments to my html emails?
Any feedback is great.
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(6)
我不这么认为。我为 Outlook 制作了几个专业的电子邮件模板,其中在评论中包含了一些注意事项。我从来没有遇到过任何问题。
我什至很高兴看到我可以找到客户发送的电子邮件,因为谷歌已将其编入索引,包括评论。 :D
它确实会稍微增加电子邮件的大小,因此请小心使用。
I don't think so. I've made several professional e-mail templates for Outlook that contained a little notice in the comments. I've never had any problems with that.
I even had fun to see that I could find an e-mail sent by a customer, because Google had indexed it, including the comment. :D
It does increase the size of the e-mail a little, so use with care.
没有,除非评论数量太多,影响浏览器/电子邮件客户端的 DOM 解析并堵塞网络流量。
None, unless the number of comments are too many that they affect DOM parsing by the browser/email client and congest network traffic.
除非你泄露了你的网络秘密,否则我不认为这有什么问题。分配的系统有注释来突出显示模板系统区域。
Unless you're revealing secrets of your network, I don't see anything wrong with it. Allot of systems have comments to highlight template system areas.
两个缺点:
Two drawbacks :
应该没问题,但我会小心处理任何带有 html 内容的电子邮件。电子邮件中的 Html 特别棘手,因为客户端(aol、outlook、gmail、thunderbird 等)可以以完全不同的方式显示结果。通过谷歌快速搜索,我找到了 emailonacid.com,这是一个电子邮件测试/送达工具,如果您想彻底了解,它可能会很有用。
It should be fine, but I would be careful with any sort of emails with html content. Html in email is particularly tricky because the clients (aol, outlook, gmail, thunderbird, etc) can display the results quite differently. A quick google search brought me to emailonacid.com, an email testing/deliverability tool which might be useful if you want to be thorough.
我最近遇到的一件事是,在嵌套 MSO 代码(用于解决 MS 产品的可见性/布局问题)时,应避免在电子邮件 HTML 中添加注释。我在 Outlook.com 中拒绝加载图像,因为 MSO 文本位于我的两条评论之间。这种语法似乎尤其让 Outlook 感到困惑。给我驱赶蝙蝠。然后我把评论拿出来,砰——图像显示出来,问题解决了。
One thing I ran into recently was that comments in email HTML should be avoided when nesting around MSO code (used for visibility/layout issues with MS products). I had an image refuse to load in Outlook.com because the MSO text was located in-between two of my comments. The syntax seemed to confuse Outlook in particular. Drove me bats. Then I took the comments out, wham -- the image displayed, problem solved.