Forums

ASP

This topic is locked

problem with Jmail

Posted 30 Sep 2007 23:34:57
1
has voted
30 Sep 2007 23:34:57 Gilles Forestier posted:
Hello,

My new hosting provider gave me its config for Jmail form :

<%
Set JMail = Server.CreateObject("JMail.SMTPMail"

JMail.ServerAddress = "...smtp server ..."

JMail.Sender = " ... email..."
JMail.Subject = "Email Subject"

JMail.AddRecipient ".... email .... "

JMail.Body = "Email contents"
JMail.Priority = 1

JMail.Execute

%>


I corrected the form that worked on the old server that way :


<%


Set JMail = Server.CreateObject("JMail.SMTPMail"
JMail.ServerAddress = "... smtp server ..."
JMail.Sender = "... mail ..."
JMail.Subject ="Formulaire de commande"
JMail.AddRecipient "... mail ...."

Dim message
JMail.Execute

on error resume next

if err then
Response.Redirect("/fra/formulaire_nok.htm"
else
Response.Redirect("/fra/formulaire_ok.htm"
end if
set JMail = Nothing

%>

It sends the (empty) message but I don't know where to include the form content (i.e. what informations people send me):

message = "Demandeur" & vbcrlf & vbcrlf
message = message & "Nom du Demandeur:" & vbcrlf
message = message & Request.Form("nomdemandeur" & vbcrlf
message = message & "Contact Demandeur:" & vbcrlf
message = message & Request.Form("contactdemandeur" & vbcrlf
message = message & "Adresse du demandeur:" & vbcrlf
message = message & Request.Form("adressedemandeur" & vbcrlf


Many thanks for your help






Reply to this topic