%@LANGUAGE="VBSCRIPT"%> <%option explicit%> <% dim email, subname, orderNumber dim strHost dim strErr dim bsuccess dim strBody, strSendername, strSenderemail strHost = "mail.omicrondeltaepsilon.org" If Request("Send") <> "" Then strSendername = Request("o_name") strSenderemail = Request("o_email") ' message body strBody = "ODE Website mail from: " & strSendername & vbcrlf strbody = strBody & "Chapter: " & Request("o_chapter") & vbcrlf strBody = strBody & "Email: " & strSenderemail & vbcrlf & vbCrlf strBody = strBody & "Subject: " & Request("o_subject") & vbcrlf & vbcrlf strBody = strBody & "Query: " & Request("p_query") & vbcrlf & vbcrlf strBody = strBody & vbcrlf & vbcrlf & "IMPORTANT NOTE: This is a dynamically generated email. Please check the address before replying." strErr = "" Const cdoBasic = 1 'Use basic (clear-text) authentication. Const cdoSendUsingPort = 2 Dim iMsg Dim iConf Dim Flds Dim sMsg Dim strTo Dim strCC Dim strFrom Dim strSubject On Error Resume Next set iMsg = CreateObject("CDO.Message") set iConf = CreateObject("CDO.Configuration") Set Flds = iConf.Fields With Flds .Item("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = cdoBasic .Item("http://schemas.microsoft.com/cdo/configuration/sendusername") = "Forms@OmicronDeltaEpsilon.org" .Item("http://schemas.microsoft.com/cdo/configuration/sendpassword") = "abc123" .Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = cdoSendUsingPort .Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = strHost .Item("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout") = 10 .Update End With strTo = "Information@OmicronDeltaEpsilon.org" strCC = strSenderemail strFrom = strSenderemail strSubject = Request("o_subject") 'Apply the settings to the message object With iMsg Set .Configuration = iConf .To = strTo .From = strFrom If strCC <> "" Then .CC = strCC End If .Subject = strSubject .TextBody = strBody 'Send message .Send End With if iMsg.SendMail then bsuccess = true else bSuccess = False On Error Resume Next ' catch errors strErr = iMsg.Response End If ' cleanup mail objects Set iMsg = Nothing Set iConf = Nothing Set Flds = Nothing end if %>
|
|||||||||||||||||
|
|||||||||||||||||
|
|||||||||||||||||
|
©2005-2010 Omicron Delta Epsilon
The International Economics Honor Society |
|||||||||||||||||