For Programmers: Free Programming Magazines  


Home > Archive > ASP > December 2006 > Re: email not getting sent. Never mind, fixed









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: email not getting sent. Never mind, fixed
Harvey Waxman

2006-12-02, 6:55 pm

Never mind.

In article <spamhwaxman-DD829F.16454602122006@news.lga.highwinds-media.com>,
Harvey Waxman <spamhwaxman@cox.net> wrote:

> Can someone see why this asp validation script doesn't send the email? The
> validations work as expected the with JS turned on or off but the email never
> gets processed. The middle portion is lifted directly from my standard asp
> file which works fine without the asp validation code. The "Response.Write
> Thanks" is shown but the email doesn't go.
>
>
> <%
> DIM strEmail, strSubject, strComments
> strEmail = Request.Form("Email")
> strSubject = Request.Form("Subject")
> strComments = Request.Form("Comments")
> IF strEmail <> "" AND strSubject <> "" AND strComments <> "" THEN
>
> Dim ObjMail
> Set ObjMail = Server.CreateObject("CDONTS.NewMail")
> ObjMail.To = "xxxx@xxxxx.com" (blanked for security)
> ObjMail.From = Email
> ObjMail.Subject = "Email"
> ObjMail.Body = "Name" & vbtab & FirstName & vbcrlf&_
> "Email" & vbtab & Email & vbcrlf&_
> "Comments" & vbtab & Comments
> ObjMail.Send
> Set ObjMail = Nothing
> Response.Write "Thanks"
>
> ELSE
> Response.Write "<p>Please click back on your browser and complete the
> following fields:</p>"
> IF strEmail <> "" THEN
> ELSE
> Response.Write "<b> Email</b><br>"
> END IF
> IF strSubject<> "" THEN
> ELSE
> Response.Write "<b> Subject</b><br>"
> END IF
> IF strComments <> "" THEN
> ELSE
> Response.Write "<b> Comments</b><br>"
> END IF
> END IF
> %>




--
Harvey Waxman
remove spam to email
http://righttax.org/
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com