Print Page | Close Window

ASP FormMail with CAPTCHA

Printed From: Web Wiz Forums
Category: Web Wiz Web App Support Forums
Forum Name: Web Wiz CAPTCHA
Forum Description: Support forum for the Web Wiz CAPTCHA security image.
URL: https://forums.webwiz.net/forum_posts.asp?TID=21570
Printed Date: 28 March 2026 at 6:03am
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: ASP FormMail with CAPTCHA
Posted By: cjpopp
Subject: ASP FormMail with CAPTCHA
Date Posted: 11 October 2006 at 11:36pm
I'm using ASP FormMail and am tired of the spam I get, so I figured I would use CAPTCHA in conjunction with the ASP FormMail script.

I've installed everything but found that the form would process if the verification was typed in wrong or right.

I can not figure out at what page to place the following:



<!-- #include file="CAPTCHA/CAPTCHA_process_form.asp" -->           
              <%

'Above we include the file that checks to see if the security code is correct

'The variable 'blnCAPTCHAcodeCorrect' will be set to true if the security code is entered correctly

If blnCAPTCHAcodeCorrect Then
     
     Response.Write("Correctly")
Else

     Response.Write("Incorrectly")
End If
              
              
              
              
              %>


Should it be on the page that processes the form (the asp file) or should it be on the page that says thanks.


-------------
______________________

Classic Rock That Matters!

9412 - The Rock Station

www.rcnradio.net



Replies:
Posted By: WebWiz-Bruce
Date Posted: 12 October 2006 at 8:04am
This goes on the processing page, but after the code is enetered incorrectly you need to then stop the process form continuing, if you don't want any more code executed.

eg.

Response.Write("Incorrectly")
Response.End



-------------
https://www.webwiz.net/web-wiz-forums/forum-hosting.htm" rel="nofollow - Web Wiz Forums Hosting
https://www.webwiz.net/web-hosting/windows-web-hosting.htm" rel="nofollow - ASP.NET Web Hosting


Posted By: cjpopp
Date Posted: 12 October 2006 at 10:13pm
I tried both of the following:

--------------------------------

     Response.Write("Correctly")
Else
     Response.Write("Incorrectly")
End If
Response.End

------------------------
     Response.Write("Correctly")
Else
     Response.Write("Incorrectly")
Response.End
------------------------

Both of those combinations did not work for me.

I've got it on the processing page with the code in the BODY area. Should it go above the </head>?

-------------
______________________

Classic Rock That Matters!

9412 - The Rock Station

www.rcnradio.net


Posted By: WebWiz-Bruce
Date Posted: 13 October 2006 at 9:45am
It needs to go at the top of the page before any processing, that you don't want running if the security code is wrong.

-------------
https://www.webwiz.net/web-wiz-forums/forum-hosting.htm" rel="nofollow - Web Wiz Forums Hosting
https://www.webwiz.net/web-hosting/windows-web-hosting.htm" rel="nofollow - ASP.NET Web Hosting



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net