【发布时间】:2019-08-14 19:05:17
【问题描述】:
我正在尝试使用我在 Godaddy 的网站上的经典 ASP 发送电子邮件。不幸的是,我 10 到 15 年前的鳕鱼不起作用(想象一下!哈哈)。这是代码。有人能告诉我从那以后发生了什么变化吗?迫切地等待您的答复。谢谢!
Set cdoConfig = CreateObject("CDO.Configuration")
With cdoConfig.Fields
.Item(cdoSMTPConnectionTimeout) = 10
.Item(cdoSMTPAuthenticate) = false
.Item(cdoSendUserName) = "email@mywebsite.com"
.Item(cdoSendPassword) = "MyPassword"
.Item(cdoURLProxyServer) = "server:25"
'.Item(cdoSendUsingMethod) = cdoSendUsingPickup
.Item(cdoSendUsingMethod) = cdoSendUsingPort
.Item(cdoSMTPServer) = "relay-hosting.secureserver.net"
.Item(cdoURLGetLatestVersion) = True
.Update
End With
'Create mail object
Set cdoMessage = CreateObject("CDO.Message")
'Apply the settings to the message object then send the email
With cdoMessage
Set .Configuration = cdoConfig
.From = "Support (email@mywebsite)"
.To = "The User (user@email.com)"
.BCC = ""
.Subject = "This is a test email."
.TextBody = "This is a test email. If it were a real email there would be some blah blah blah here! This concludes the test of the Godaddy email message."
.Send
End With
'Cleanup mail objects
Set cdoMessage = Nothing
Set cdoConfig = Nothing
【问题讨论】:
-
CDO 正常工作(不管它有多旧) 问题将是电子邮件提供商的详细信息发生了某种变化,请在指向之前仔细检查提供商信息是否正确首席数字官的手指。
-
我想通了。下面回答。我现在可以拿回我的积分吗?请!
标签: email asp-classic godaddy-api