% ' Single quotes at the begining of a line mean it's a comment, and doesn't execute. 'This detects that we're posting from the form if Request.ServerVariables("REQUEST_METHOD") = "POST" then ' Required. Create the object for use... Set Mail = Server.CreateObject("IARNA.ASPEmail") ' Required. Set who the mail is from in an email address string. ' Property ' Usage = mailObj.From = string Mail.From = "info@7starwebservices.com" ' Specify sender's address ' Optional. Set the friendly name for the email address. ' Property ' Usage = mailObj.From = string Mail.FromName = "7 Star Web Services" ' Specify sender's name ' Required at least once. Set the recipient of the email. ' Method. ' Usage = mailObj.AddAddress emailAddress as string, friendlyname as string Mail.AddAddress "info@7starwebservices.com", "7 Star Web Services" ' Don't 'have to put anything in the quotes, but you must have the empty quotes. ' Optional at least once. Set the Carbon Copy of the email. ' Method. ' Usage = mailObj.AddCC emailAddress as string, friendlyname as string ' Mail.AddCC "", "" ' Don't have to put anything in the 'quotes, but you must have the empty quotes. ' Optional. Set the Blind Carbon Copy of the email. ' Method. ' Usage = mailObj.AddBCC emailAddress as string, friendlyname as string Mail.AddBCC "alecmaran@aol.com", "Al Eccles" ' Don't have to put 'anything in the quotes, but you must have the empty quotes. ' Optional. You can change the Reply To address for your email. ' Method. ' Usage = mailObj.AddReplyTo String ( email address ) Mail.AddReplyTo "info@7starwebservices.com" ' Optional. You can add attachments to send with your message. Ensure the 'files are inside your WebDirectory ' Method. ' Usage = mailObj.AddAttachment PathToFileToAttach (string) 'Mail.AddAttachment Server.MapPath("/emailAttachments/filetoattach.txt") ' Optional. You can use AddCustomHeader to add extra headers to the top of 'the message, for use in mail filtering etc. ' Method. ' Usage = mailObj.AddCustomHeader string 'Mail.AddCustomHeader "X-Custom-Extra-Header: true" ' Optional. This is the Subject line of the email. ' Property. ' Usage = mailObj.Subject = string Mail.Subject = "7 Star Web Services Online Form Submission - ASP Email COM Object" ' Optional. Priority is set from 1 to 5, with 5 being the lowest. ' Property. ' Usage = mailObj.Priority = integer ' Mail.Priority = 1 ' Optional. Set it when you're sending HTML email to format the message 'correctly. ' Property ' Usage = mailObj.IsHTML = boolean ( true/false ) Mail.IsHTML = false 'this gets everything in the form and puts it in a variable to send in the body for each item in Request.Form tmpstring = tmpString & item & " : " & Request.Form(item) & vbCRLF next ' Required. This is the body of text you'd like to send to the addresses 'given. ' Usage = mailObj.Body = String Mail.Body = tmpString ' Optional. This AltBody will appear as an Alternative to the HTML Email. ' Usage = mailObj.AltBody = String Mail.AltBody = "Not HTML Email." ' Optional. This will allow you to embed an image in your mail. ' Usage = mailObj.AddEmbeddedImage pathToFile, ContentID 'Mail.AddEmbeddedImage "c:\temp\moby.jpg","Moby-CD" On Error Resume Next PossErr = Mail.Send If PossErr <> 0 Then wscript.echo "Error encountered: " & Mail.Response End If Response.Redirect "http://www.7starwebservices.com" ' where you want to go end if %>
|
Web Design Questionnaire - Free Quote - 7 Star Web Services Online Form Web Design - E Commerce Hosting - Graphics - Flash Animation - Streaming - Office - Translation TEL: + 44 (0) 1494 766 938 |Info@7starwebservices.com | Homepage | Contact Us |
||||
|
7 Star Web Services Online Order Form & Questionnaire |
||||
|
Secure Trust-e Paypal Online Shopping Cart All
Major Credit Cards Accepted Design & Hosting | Graphics | Animation | Streaming | Office Support | Translation | Sales Copyright © 2000 - 2002 - 7StarWebServices.com - All Rights Reserved |7 Star Web Services | VAT No: 727 6801 18 |
||||