什么是使用System.Net.Mail时格式化电子邮件的最佳方法

问题描述:

您好,我使用 System.Net.Mail 发送一些HTML格式的电子邮件。

Hi I'm using System.Net.Mail to send some HTML formatted emails.

正确的方法插入css到电子邮件消息?

What is the correct method for inserting css into the email message?

我知道我可以应用格式化每个项目,但我想使用样式表..

I know I can apply formatting to each item, but I'ld rather use style sheets..

EDIT
我应该提到这是一个内部应用程序,我希望99%的用户使用Outlook或其他客户端,

EDIT I should have mentioned that this is for an internal application, and I expect 99% of users to be using Outlook or other client, but never hotmail or gmail etc.

我一直发现严格使用 HTML 3.0兼容的标签和格式最适合所有电子邮件阅读者和提供者。

I've always found that strictly using HTML 3.0 compatible tags and formatting works best for all email readers and providers.

但这里是 电子邮件中的CSS 文章,您可以找到解决您的问题的解决方案。

nevertheless here is a CSS in Email article that may answer your question, you will find solutions to your css problems.