|
Mailto Form Problems
|
Logged in as: Guest
|
Name: | |
|

TexasWebDevelopers
Posts: 7039
Member since: 9/24/2002
From: USA

|
RE: Mailto Form Problems (in reply to jk15060)
|
|
|
Hi Janis, You do not want to use the FrontPage extensions to do this at all. The form can be .htm but the email processing page needs to be an asp page. The structure is simple--create the form; have the form "post" to an asp page ..call it whatever you want...on the asp page is the simple code to get the form fields from the form; the CDONTS code that sends the email; and a redirect that thanks the user after the email has been sent: <% name = Trim(Replace(Request.Form("name"),"'","")) eMail_Address = Trim(Replace(Request.Form("eMail_Address"),"'","")) comments = Trim(Replace(Request.Form("comments"),"'","")) 'This sends and email to the person who filled out the form and a bcc to you Dim str str = "Information Request from TWD" & vbCrLf & vbCrLf str = str & "Contact information From: " & vbCrLf str = str & "Name: " & Request.Form("name") & vbCrLf str = str & "mailto:" & Request.Form("eMail_Address") & vbCrLf str = str & "Comments:" & Request.Form("comments") & vbCrLf & vbCrLf Dim myMail Set myMail = Server.CreateObject("SMTPsvg.Mailer") myMail.RemoteHost = "mail.yoursite.com" myMail.FromAddress = "info@yoursite.com" myMail.AddRecipient Request.Form("name"), Request.Form("eMail_Address") myMail.AddBcc "you", "you@yoursite.com" myMail.Subject = "Thank you" myMail.BodyText = str myMail.SendMail Set myMail = Nothing Response.Redirect("thankyou.asp") %>
_____________________________
FrontPageTools.com:Templates, Tools and Training support this forum
|
|
|
|
Report Abuse |
Date: 8/24/2008 4:15:39 PM
 |
|
New Messages |
No New Messages |
Hot Topic w/ New Messages |
Hot Topic w/o New Messages |
Locked w/ New Messages |
Locked w/o New Messages |
|
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts
|
|
|