发送电子邮件至 hotmail 收件箱

发布于 2024-10-28 04:35:16 字数 206 浏览 1 评论 0原文

我正在尝试使用 c# MailMessage 向 hotmail 帐户发送电子邮件,但电子邮件总是变成垃圾邮件。

如何在 C# 中直接将电子邮件发送到 hotmail 收件箱?

我没有自己的 smtp 服务器,因此我尝试使用我的大学 smtp 和其他 smtp,如 google、yahoo...但所有电子邮件都被发送到垃圾邮件。

有什么解决办法吗?

I am trying to send an email using c# MailMessage to a hotmail account but the emails are always going to junk.

How can i send emails directly to hotmail inbox in c#?

I don't have my own smtp server, therefore i have tried using my university smtp and other smtps like google, yahoo... but all emails were sent to junk.

Any solutions?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(5

煮茶煮酒煮时光 2024-11-04 04:35:16

这实际上并不是一个 C# 问题。

邮件会根据其内容和标题发送到垃圾邮件,因此您应该检查一些事项:

  • 您需要有一个主题,
  • 不应包含垃圾邮件单词(性、伟哥、爱情、手表)
  • 您需要有一个返回和匹配的发件人地址标头
  • 您需要与您的编码保持一致,如果您选择 UTF8 发送 UTF8 文本
  • 您不应该插入图像
  • 您的邮件内的链接(如果有)应该将其文本设置为它们要去的地址使用

这些策略应该有助于您的电子邮件不被归类为垃圾邮件。

您始终可以检查其中一封垃圾邮件的标头。通常会描述应用了哪些规则以及邮件在何处失败。

This is not really a C# question.

Mails are sent to spam depending on their content and their headers so you should check a few things :

  • You need to have a subject
  • you shouldn't have spammy words (sex, viagra, love, watches)
  • You need to have a return-to and a from address headers that match
  • You need to be consistent with your encoding, if you go for UTF8 send UTF8 text
  • You shouldn't insert images
  • Your links inside the mail, if any, should have their text set to the address they are going to

Using these strategies should help your email not being classified as spam.

You can always check the headers of one of the mail that went into spam. It is often described what rules were applied and where the mail failed.

忘东忘西忘不掉你 2024-11-04 04:35:16

在 hotmail 中,打开“垃圾邮件”文件夹,单击该邮件。 Hotmail 将在邮件正文中显示选项 - 单击“等等,很安全!” Hotmail 会将邮件移至您的收件箱,并将发件人电子邮件地址标记为安全。

您的代码(可能)没有任何问题 - 它是将发件人和/或主题识别为垃圾邮件的 hotmail。

In hotmail, open the Junk folder, click on the message. Hotmail will display options in the body of the message - click on "Wait, it's safe!" Hotmail will move the message to your inbox, and mark the FROM email address as safe.

There is (probably) nothing wrong with your code - it is hotmail identifying the sender and/or subject as being junk.

江城子 2024-11-04 04:35:16

虽然垃圾邮件过滤器很可能超出您的控制范围,但通常在加权系统上工作,因此您可以采取一些措施来使您的电子邮件看起来不像垃圾邮件。

首先,请检查:

  • 您的主题不包含全部大写或敏感词(例如“免费!”)
  • 您的正文包含内容
  • MailMessage 的“发件人”地址存在。

如果这些都很好,请查看此列表live.com 上的这篇文章Hotmail 的政策、实践和指南

Although it may well be out of your control, junk email filters generally work on a weighting system, so there are things that you can do to make your email look less like spam.

To start with, check that:

  • your subject doesn't contain all caps or sensitive words (such as "FREE!")
  • your body has content
  • the 'from' address for the MailMessage exists.

If those are all fine, have a look through this list, this article on live.com and the Policies, Practices and Guidelines for Hotmail.

躲猫猫 2024-11-04 04:35:16

您的邮件内容是什么,是否是可能被垃圾邮件过滤器视为垃圾邮件的文本?您是否尝试过发送至其他帐户(例如 Yahoo 或 Gmail)?

What is the content of your mail, is it text that is likely to be regarded as junk mail by spam filters? Have you tried sending to other accounts such as Yahoo or Gmail?

烟柳画桥 2024-11-04 04:35:16

你不能从 C# 做到这一点。
收件人可以将邮件路由到垃圾邮件箱或收件箱或决定将邮件放入的任何位置。如果允许发件人决定将邮件发送到客户端的何处,想象一下垃圾邮件的问题将会有多大。

您可以采用的一种解决方案是让您的目标邮件帐户将发件人列入“白名单”,但这可能并非在所有情况下都是一种选择。

You can't do it from C#.
It is up to the recipient to route the messages to junk or inbox or wherever it decides to put the message. If the sender were allowed to decide where the message went on the client's side, imagine how much bigger of a problem spam would be.

One solution you can employ is to have your target mail account 'whitelist' the sender, but that may not be an option in all cases.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文