[thelist] ASPMail

Michele Foster michele at wordpro.on.ca
Sat Jan 25 09:38:01 CST 2003

Hi Kevin ..

A couple of ideas .. can you get the mail to send directly without using
form values?  If that's working, then there's something wrong with the data
coming through from your form.  Are you using a VALID email address?
AspSmartMail will definitely fail if the address isn't valid (I can't
remember how strict aspmail was/is on this).. so I validate the address
before even trying to send it through the mail script.  Another possibility
is if the "name" value from your form is empty, the mail script may not like
that.  In my case, I check that first too, but I don't insist a person enter
anything on the form, if it's empty, I put name="No name entered" and use
that value in my mail script.  Are you sure you have your mail host correct?

So, my suggestions would be ..

(1)  Get the email processing working with real values first .. directly in
your script without the form values.
(2)  Once you're sure it WILL work .. then add some validation to verify the
values coming from the form are valid .. and if not, decide how you want to
deal with them.

Don't forget to trim your values coming from the form .. that could also
cause a problem. And set mailer=nothing at the end of it all too.



----- Original Message -----
From: "Kevin Stevens" <kjs at ratking.co.uk>

> response.write request.form("vol_email")
> response.write request.form("name")
> Set Mailer = Server.CreateObject("SMTPsvg.Mailer")
> Mailer.FromName   = request.form("name")
> Mailer.FromAddress= request.form("vol_email")
> Mailer.RemoteHost = "compvoltalk.co.uk"
> Mailer.AddRecipient "KJS", "testing at ratking.co.uk"
> Mailer.Subject    = "Visit to " &(request.form("client_name"))
> Mailer.BodyText   = request.form("details")
> if Mailer.SendMail then
>   Response.Write "Mail sent..."
> else
>   Response.Write "Mail send failure. Error was " & Mailer.Response
> end if
> and the error I'm getting is this...
> testing at ratking.co.ukkjsMail send failure. Error was 503 must have sender
> and recipient first

More information about the thelist mailing list