Frage

I am creating a system where users will book days and those days will be processed by various people. Once the user has made the booking, I would like the people who process the booking to receive an email telling them a booking has been made for them to process. I am using HTML, ASP classic and SQL (in SQL Server). I want to know what is the best way to send an email using one of these language. I can only seem to find answers for languages I don't know and would like to be able to understand what has been written, if a future problem occurs, thanks.

War es hilfreich?

Lösung

this is the answer to my question, the other answer did not work because it hadn't been set up with a SMPT server this is what I now use:

Set myMail=CreateObject("CDO.Message")
myMail.Subject="SUBJECT"
myMail.From="FROM EMAIL"
myMail.To="TO EMAIL"
myMail.TextBody= "TEXT BODY"
myMail.Configuration.Fields.Item _
("http://schemas.microsoft.com/cdo/configuration/sendusing")=2
'Name or IP of remote SMTP server
myMail.Configuration.Fields.Item _
("http://schemas.microsoft.com/cdo/configuration/smtpserver")="exchangeremote.webappuk.com"
'Server port
 myMail.Configuration.Fields.Item _
 ("http://schemas.microsoft.com/cdo/configuration/smtpserverport")=25 
 myMail.Configuration.Fields.Update
 myMail.Send
 set myMail=nothing

Andere Tipps

You can try something like this:

<%
Set Mail=CreateObject("CDO.Message")
Mail.Subject="Email subject"
Mail.From="from@domain.com"
Mail.To=to@domain.com
Mail.ReplyTo ="replyto@domain.com"
Mail.HTMLBody = "<h1>This is an email message.</h1>"
Mail.Send
set Mail=nothing
%>
Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top