Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 586509
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T15:06:52+00:00 2026-05-13T15:06:52+00:00

I have integrated Recaptcha with dJango. dJango Snippet – Recaptcha The view which is

  • 0

I have integrated Recaptcha with dJango.
dJango Snippet – Recaptcha

The view which is showing the page is –
from baseapp.recaptcha import captcha

def showHome(request):    
    if(request.user.is_authenticated()):    
        tempEmail = request.session.get('id')    
        return render_to_response('logreg/login-register.html',   {'emailFromForm':tempEmail}, context_instance=RequestContext(request));    
    else:    
        request.session.set_test_cookie()    
        form = RegistrationForm()    
        loginForm = LoginForm()    
        html_captcha = captcha.displayhtml(settings.RECAPTCHA_PUB_KEY)    
        print "Captcha HTML is : %s" % html_captcha    
        return render_to_response('logreg/login-register.html', {'form': form, 'loginForm':loginForm, 'html_captcha':html_captcha})    `

Here is the code in html –

<div id="register-dialog" title="Register yourself">    
  <p id="validateTips">All form fields are required.</p>    
  {% if error %}    
  {{ error }}    
  {% endif %}    
  <form name="registrationForm" action="registerUser/" method="post">    
      {{ form.as_p }}    
      {{ html_captcha }}    
  </form>    
</div>

It works great in IE & Chrome, but firefox shows me an exception at line 451 in recaptcha.
Here is the code at that line var $ST = RecaptchaState;

Any thoughts are appreciated !

Note : Firefox version – 3.6; IE – 8; Chrome – 4.0

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T15:06:52+00:00Added an answer on May 13, 2026 at 3:06 pm

    Here is how I solved it.

    I figured that my captcha is being shown inside the jqueryui dialog and maybe that is the problem with FF. (Why ? I don’t know.)
    Hence instead of statically putting the text there from django or writing it out.
    I used the ajax api and inserted the recaptcha on the open event on the dialog.

    Here is the sample code, just in case someone stumbles upon the same issue.

    Code is almost similar to what is on the reCaptcha api site

    $("#register-dialog").dialog({    
        buttons:{
        },    
        open: function() {
        Recaptcha.create("41x39....",
            "recaptcha_div", {
            theme: "red",
            callback: Recaptcha.focus_response_field
            });
    

    And changed the form tag to be so –

    <form name="registrationForm" action="registerUser/" method="post">    
        {{ form.as_p }}    
        <div id="recaptcha_div"></div>    
    </form>
    

    And yes, included the ajax.js –

        <script type="text/javascript" src="http://api.recaptcha.net/js/recaptcha_ajax.js">
        </script>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i have integrated Fbconnect in LoginViewController.I want to logout the session from another view
I have integrated sIFR3 and it shows perfectly in my home page but not
I have integrated evernote in my application by downloading sample code from its site.
I have integrated the facebook in to my application, From the FB i will
I have a 2 sites integrated into one, wordpress is my second site which
http://code.google.com/p/django-threadedcomments/,I have integrated the the following Blog APP with my site.In the URLs.py i
I have integrated NHibernate.Search into my web app by following tutorials from the following
I have integrated spring security plugin with my grails application, which has hibernate as
I have integrated a library that uses AVCaptureSession to capture a photo from the
I have integrated my Spring application with GWT. My application has a Login page

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.