Forums

This topic is locked

Making Email and DB Insert Form

Posted 19 Dec 2001 23:24:19
1
has voted
19 Dec 2001 23:24:19 Jeff Hansen posted:
I am trying to make a page that will allow the uesr to enter info and select from drop downs, then info will be entered into the DB (that i can handle), but I also need the form to be emailed out... I have no clue how to do this, any help???


JEFF

Replies

Replied 25 Dec 2001 20:43:58
25 Dec 2001 20:43:58 Michael Moore replied:
Jeff, take 20 minutes to study CDONTS. It is a mechanism provided by Microsoft (ever hear of them?) that gives the email functionality. It is really easy to use. good luck

Replied 02 Jan 2002 16:04:10
02 Jan 2002 16:04:10 Mark Labordus replied:
QuoteJust to give you an idea..
If you're in need of values from a form, use Request.Form("myEditBox_or_something".Value

Dim Emfrom
Dim Emsub
Dim Emto
Dim Embody
Dim ObjCdo

Emsub = "Message from my website (www.unknown-epals.com)."
Emfrom = " "
Emto = " "
Embody = "Hello my friend, " & vbCrLf & _
"This message is to remind you of the data you need to login." & vbCrLf & vbCrLf & _
"------ LOGIN INFORMATION ------" & vbCrLf & vbCrLf & _
"Username = " & "username" & vbCrLf & _
"Password = " & "password" & vbCrLf & vbCrLf & _
"Bye!!"

Set ObjCdo = Server.CreateObject("CDONTS.NewMail"
ObjCdo.From = Emfrom
ObjCdo.Subject = Emsub
ObjCdo.To = Emto
ObjCdo.body = Embody

ObjCdo.send
Set ObjCdo = nothing

Replied 07 Jan 2002 14:33:04
07 Jan 2002 14:33:04 Craig Stanton replied:
Is there any way to do this same thing (send info to a database AND to an email address) if I am using .jsp?

Thanks!
Craig

Reply to this topic