% Option Explicit Dim strMailFrom Dim strMailSubject Dim strMailTo '''''''''''''''''''''''''''''''''''''''''''''''''''''''''' ' Edit these next 3 variables ' ' ' '''''''''''''''''''''''''''''''''''''''''''''''''''''''''' strMailFrom = "webmaster@avi-indy.com" strMailSubject = "Form Submission" strMailTo = "info@avi-indy.com" '''''''''''''''''''''''''''''''''''''''''''''''''''''''''' ' Don't edit anything after this. ' ' ' '''''''''''''''''''''''''''''''''''''''''''''''''''''''''' 'Declare all variables Dim First Dim Last Dim textarea Dim strRequest Dim PhoneNo Dim AltPhoneNo Dim EmailId Dim objMail Dim strMailBody 'Grab variable values from the submitted form First = Request("First") Last = Request("Last") textarea = Request("textarea") strRequest = Request("Request") PhoneNO = Request("phone1") AltPhoneNo = Request("phone2") EmailId = Request("email") 'setup the email portion of the script Set objMail = CreateObject("CDO.Message") objMail.Subject = strMailSubject objMail.From = strMailFrom objMail.To = strMailTo objMail.Configuration.Fields.Item _ ("http://schemas.microsoft.com/cdo/configuration/sendusing")=2 'Name or IP of remote SMTP server objMail.Configuration.Fields.Item _ ("http://schemas.microsoft.com/cdo/configuration/smtpserver") _ ="mail.ori.net" 'Server port objMail.Configuration.Fields.Item _ ("http://schemas.microsoft.com/cdo/configuration/smtpserverport") _ =25 objMail.Configuration.Fields.Update 'Create body of message by combining variables and html strMailBody = "Here are the results from your form:" & vbcrlf&_ "First: " & First & vbcrlf&_ "Last: " & Last & vbcrlf&_ "Address: " & textarea & vbcrlf&_ "Request of Services: " & strRequest & vbcrlf&_ "Phone Number: " & PhoneNo & vbcrlf&_ "Alternate Phone Number: " & AltPhoneNo & vbcrlf&_ "E-Mail: " & EmailId & vbcrlf objMail.TextBody = strMailBody 'Send email objMail.Send 'reset variable to null to avoid errors set objMail = nothing '''''''''''''''''''''''''''''''''''''''''''''''''''''''''' ' End of Script ' ' ' '''''''''''''''''''''''''''''''''''''''''''''''''''''''''' %>
|
||||||
©Copyright 2004 AVI. All
Rights Reserved. Site Design by Online Now! |