Using ASPEmail
Here is a snippet of code to use to access the ASPEmail feature on Windows accounts.
<%
Set Mail = Server.CreateObject("Persits.MailSender")
Mail.Host = "mail.example.com" ' Specify a valid SMTP server
Mail.Username = "username@example.com" 'Login as email account
Mail.Password = "email account password" 'Password for the email account
Mail.From = "sales@example.com" ' Specify sender's address
Mail.FromName = "Example Name" ' Specify sender's name
Mail.AddAddress "john@example.net", "John Doe"
Mail.AddAddress "paul@example.net" ' Name is optional
Mail.AddReplyTo "info@example.com"
Mail.AddAttachment "example.jpg"
Mail.Subject = "Example Subject"
Mail.Body = "Dear Sir:" & Chr(13) & Chr(10) & _
"Thank you for your business."
On Error Resume Next
Mail.Send
If Err <> 0 Then
Response.Write "Error encountered: " & Err.Description
End If
%>
Mail.Host should be mail.yourdomain.com
Mail.From MUST be an email address setup on your account.
*For more information about AspEmail's features visit www.aspemail.com