Classic ASP email script no longer working

lucianocrack

New Member
I created a 'sendmail' script in ASP a few years ago, including email format validation and CAPTCHA validation. It worked well.I've not received any enquiries through the form for a while now so thought I would test the contact page myself. Lo and behold, the script no longer seems to work. Does anyone know if my method (please see below) has become obsolete over the past few years?! Is there now a different recommended way of doing this in (classic) ASP?Here is the first part of my script (email addresses changed for privacy):\[code\]<%Dim mailDim msgtextSet mail = CreateObject("CDO.Message")mail.To = "[email protected]"mail.Cc = "[email protected]"mail.From = Request.Form("From")mail.Subject = "Enquiry from website"mail.TextBody = "From: " & Request.Form("Fname") & vbCRLF & "Message: " & Replace(Request.Form("Body"),vbCrLf ,"") & vbCRLF & "Telephone: " & Request.Form("Phone") & vbCRLFif not IsEmpty(Request.Form("btnTest")) then if TestCaptcha("ASPCAPTCHA", Request.Form("captchacode")) then else msgtext = "c" end ifend ifmail.Send()'Destroy the mail object!Set mail = nothingmsgtext = "y"%>\[/code\]
 
Back
Top