Scooter Posted March 31, 2005 Posted March 31, 2005 I'm new to creating web pages, and the question i have is this, I have created a web form that collects a person's data (name, address,etc.) but I'm not quite sure how to have that data e-mailed to me automatically after they press the submit button. http://www.xtremedotnettalk.com/newthread.php# Confused Quote Whenever, wherever, whatever
michael_hk Posted April 1, 2005 Posted April 1, 2005 Should use something like <form enctype="text/plain" action="mailto:test@test.com"> <input.....> </from> Quote There is no spoon. <<The Matrix>>
Scooter Posted April 1, 2005 Author Posted April 1, 2005 Won't this cause their default e-mail program to come up with my e-mail address showing in the address bar. I want it to automatically send the data in the form directly to my e-mail address, without any user intervention other than pressing the submit button. Quote Whenever, wherever, whatever
bri189a Posted April 1, 2005 Posted April 1, 2005 Dim email As New System.Web.Mail.MailMessage() email.To = "RecipientAddress" email.From = "SenderAddress" email.Body = "MessageText" email.Subject = "SubjectText" email.BodyFormat = Web.Mail.MailFormat.Text System.Web.Mail.SmtpMail.SmtpServer = "SmtpServerName" System.Web.Mail.SmtpMail.Send(email) Your web server has to have Smtp mail to do this and may require other properties to be set. I've never done it before, I just knew the namespace to look in for you. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.