Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - CAPTCHA Code Still Not Working
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Forum LockedCAPTCHA Code Still Not Working

 Post Reply Post Reply Page  123>
Author
Tomcat View Drop Down
Newbie
Newbie


Joined: 30 October 2006
Location: United States
Status: Offline
Points: 7
Post Options Post Options   Thanks (0) Thanks(0)   Quote Tomcat Quote  Post ReplyReply Direct Link To This Post Topic: CAPTCHA Code Still Not Working
    Posted: 14 November 2006 at 8:08pm
I have read through all of the posts on Captcha (found by keyword search) and tried troubleshooting, but still can't get it to work.  Perhaps my understanding of how the programs work and fit together is foggy.
 
Here is my latest error message:
 

Microsoft VBScript compilation error '800a0411'

Name redefined

/hauntedhouse/CAPTCHA/CAPTCHA_setup.asp, line 54

Dim blnCAPTCHAabout

----^

I am not sure where I need to declare this variable.

Here is the Captcha code that is INSIDE my form:
 
<!-- include the Web Wiz CAPTCHA form -->

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

<br>

<p><span class="style7">Enter the code exactly as you see it in the image:-<br />

    (Cookies must be enabled)</span><br />

    &nbsp;</p>

 

<!-- Include file for CAPTCHA form processing -->            

<!-- #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

             

%>
 
I didn't write any other conditions yet because I wanted to see if it passed through the first step.
 
I am using CDONTS for my email processesor.  So I have a emailform.asp file that processes the CDONTS email component.
 
So there are three key files:  the form file, the CDONTS file, and the Thank You file that the user gets when the form results were successfully emailed.
 
Please someone help me.   Thanks greatly.
Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 15 November 2006 at 9:56am
The error means you are declaring the variable multiple times. You can only use the following line once in a file:-

Dim blnCAPTCHAabout
Back to Top
Tomcat View Drop Down
Newbie
Newbie


Joined: 30 October 2006
Location: United States
Status: Offline
Points: 7
Post Options Post Options   Thanks (0) Thanks(0)   Quote Tomcat Quote  Post ReplyReply Direct Link To This Post Posted: 15 November 2006 at 12:26pm

I must be confused as to what file includes should be in my form.

My form includes my own variables and then includes two files:
CAPTCHA/CAPTCHA_form_inc.asp and CAPTCHA/CAPTCHA_process_form.asp
 
From what I understand, the CAPTCHA_form_inc.asp file has the captcha field and the CAPTCHA_process_form.asp file checks to see if the security code was properly entered.
 
The CAPTCHA_form_inc.asp file calls CAPTCHA_setup.asp by an #include which
initializes the blnCAPTCHAabout variable.  The CAPTCHA_form_inc.asp file  uses  the variable blnCAPTCHAabout, which refers to the copyright.
 
The CAPTCHA_process_form.asp also calls the CAPTCHA_setup.asp files that again initializes the blnCAPTCHAabout variable.
 
Since I should not make any changes to your code, I am at a loss as what to do.  I was thinking that the code to check the correctness of captcha entry should be in the same form file with the rest of the form fields.  In order for that to happen, both the CAPTCHA_form_inc.asp and the CAPTCHA_process_form.asp files need to be in the same form file.  Right? Or am I missing something.  Both of these files include the CAPTCHA_setup.asp which initializes the blnCAPTCHAabout variable.  So I understand your comment.
 
But, what should I do to accomplish what I need without changing any of the code in your CAPTCHA files?
 
Sorry that I am such a newbie.  Please light my lightbulb!  Thanks.
 
 
 
 
Back to Top
bobmac View Drop Down
Newbie
Newbie


Joined: 18 November 2006
Status: Offline
Points: 5
Post Options Post Options   Thanks (0) Thanks(0)   Quote bobmac Quote  Post ReplyReply Direct Link To This Post Posted: 18 November 2006 at 11:34pm
I'm also stuck on the same issue. Hopefully, someone will shed some light on how to solve this. Meanwhile, I'm stumped and stopped!  Cry
Back to Top
dpyers View Drop Down
Senior Member
Senior Member


Joined: 12 May 2003
Status: Offline
Points: 3937
Post Options Post Options   Thanks (0) Thanks(0)   Quote dpyers Quote  Post ReplyReply Direct Link To This Post Posted: 18 November 2006 at 11:59pm
Originally posted by bobmac bobmac wrote:

I'm also stuck on the same issue. Hopefully, someone will shed some light on how to solve this. Meanwhile, I'm stumped and stopped!  Cry

http://forums.webwiz.net/forum_posts.asp?TID=21951

Lead me not into temptation... I know the short cut, follow me.
Back to Top
bobmac View Drop Down
Newbie
Newbie


Joined: 18 November 2006
Status: Offline
Points: 5
Post Options Post Options   Thanks (0) Thanks(0)   Quote bobmac Quote  Post ReplyReply Direct Link To This Post Posted: 19 November 2006 at 12:10am
Thanks, but I don't think that link solves my issue. Mine is one where as soon as I attempt to load the page with <!-- #include file="CAPTCHA/CAPTCHA_process_form.asp" --> at the very top of the page with the other include files and <!--#include file="CAPTCHA/CAPTCHA_form_inc.asp" --> in the spot where I want the CAPTCHA to appear (right above the submit button), I get an error page with 

Microsoft VBScript compilation error '800a0411'

Name redefined

/CAPTCHA/CAPTCHA_setup.asp, line 54

Dim blnCAPTCHAabout
----^

I'm just trying to get the page loaded. Is that any clearer? (After I get this one fixed, then I'll go on to the variables issue.)
Back to Top
dpyers View Drop Down
Senior Member
Senior Member


Joined: 12 May 2003
Status: Offline
Points: 3937
Post Options Post Options   Thanks (0) Thanks(0)   Quote dpyers Quote  Post ReplyReply Direct Link To This Post Posted: 19 November 2006 at 4:42am
CAPTCH can't be used in a form that submits to itself.
<!--#include file="CAPTCHA/CAPTCHA_form_inc.asp" --> goes into the .asp form page
<!-- #include file="CAPTCHA/CAPTCHA_process_form.asp" --> goes into a different .asp form handler page.

Lead me not into temptation... I know the short cut, follow me.
Back to Top
Davecl View Drop Down
Newbie
Newbie
Avatar

Joined: 22 November 2006
Location: United Kingdom
Status: Offline
Points: 10
Post Options Post Options   Thanks (0) Thanks(0)   Quote Davecl Quote  Post ReplyReply Direct Link To This Post Posted: 22 November 2006 at 7:10am
Originally posted by dpyers dpyers wrote:

CAPTCH can't be used in a form that submits to itself.
 
i believe it can, i got it working on a registration form written in DW8.02, however after probs with 8.02 i have gone back to 8.01 and can't get it working, i will keep trying though and let you know when(if) i get it working Tongue
Back to Top
 Post Reply Post Reply Page  123>

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.