Macrotone Blogs

Macrotone blogs upon Joomla, our products and other matters.
Font size: +

ReCaptcha disappeared from User Registration.

ReCaptchaWe were recently informed of a problem on our site where the ReCaptcha image was not being displayed.  This was puzzling since we hadn’t changed anything and the image was showing in other locations upon the site, such as adding article comments etc.

We were aware of a few changes a year or so ago by Google but are not aware of any recent changes.  After some searching we found this article which described our problem and provided a solution that appears to work well.

We had already checked that Method 1 in the article didn’t resolve the problem so we used Method 2 which we reproduce below.

This overrides the Core Joomla code for ReCaptcha:
1. Open the file: /plugins/captcha/recaptcha/recaptcha.php
2. Find the following string in the OnDisplay function:

return '<div id="dynamic_recaptcha_1"></div>'; 

3. and replace with:

   1:  // Replace YOUR_KEY with your public key 
   2:   
   3:   return '<div id="dynamic_recaptcha_1"> 
   4:   <script type="text/javascript" src="http://www.google.com/recaptcha/api/challenge?k=YOUR_KEY"></script> 
   5:   <noscript><iframe src="http://www.google.com/recaptcha/api/noscript?k=YOUR_KEY" height="300" width="500" frameborder="0"></iframe><br> 
   6:   <textarea name="recaptcha_challenge_field" rows="3" cols="40"></textarea> 
   7:   <input type="hidden" name="recaptcha_response_field" value="manual_challenge"></noscript> 
   8:   <script type="text/javascript"> 
   9:   window.onload = function() { 
  10:   Recaptcha.focus_response_field(); 
  11:   } 
  12:   </script> 
  13:   </div>'; 

 

 

We have tested using Firefox, Chrome and IE and in all cases we now see the ReCaptcha image, where as previously we were not.

The following additional comments were present in the original article and also apply in our situation.

Additional

  • This applies to a case where the code WAS working and without any changes to the server (no updates), and the recaptcha simply stopped displaying.
  • Public Key and Private Key have been setup in the Joomla Core Plugin.
  • Set to display in both User Registration and Global Configuration.
  • K2 is NOT installed.

Note Well:

This change would have to be reapplied if the plugin is updated by any future update from Joomla, but at least the site user registration is working correctly!

Canvas Fingerprint code tracking
Pavlovian approach to Password Management.
 
Go To Top

Joomla! Debug Console

Session

Profile Information

Memory Usage

Database Queries