|
|
|
Sending mail using a script
When your account is activated, it creates an application on the domain which allows you to execute ASP.
Your ASP code can use any of the following components:
CDONTS (Microsoft's CDO for NTS Library) - refer to http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cdo/html/_denali_newmail_object_cdonts_library_.asp
JMail refer to http://www.dimac.net
Example:
The following example uses CDO:
<%
dim objmail ' create variable
set objmail = server.createobject("CDONTS.Newmail") ' create object
objmail.to = "you@yourcompany.com" ' recipient
objmail.from = "me@mycompany.com" ' sending address
objmail.subject = "This is a test mail" ' set the subject
objmail.date = "This is a test mail generated by CDO for NTS" ' set the body of the message
objmail.send ' send the mail
set objmail = nothing ' clear the object
%>
Warnings:
1. Do not forget to clear the mail object at the end of the script.
2. All the components use SMTP (Simple Mail Transfer Protocol), and you should be aware that all Espinda' SMTP servers have filters which ensure that either the 'to' or 'from' address relates to one of your domains hosted by Espinda, and that the 'from' address is not blank.
|
|
|