my code stock.com

Recapcha does not being displayed in joomla 2.5.xx
The javascript lib unsecure link (http://api.recaptcha.net/js/recaptcha_ajax.js) is broken.Change the link to secure one.
change it to https://www.google.com/recaptcha/api/js/recaptcha_ajax.js
edit :/pulgins/captcha/recaptcha/recaptcha.php

Snippet options

Download: Download snippet as captcha-recaptcha-bug.php.
Copy snippet: For this you need a free my code stock.com account.
Embed code : You will find the embed code for this snippet at the end of the page, if you want to embed it into a website or a blog!

class plgCaptchaRecaptcha extends JPlugin
{
   const RECAPTCHA_API_SERVER =  "https://www.google.com/recaptcha/api";// FIXME: put that instated of this:"http://api.recaptcha.net";
   const RECAPTCHA_API_SECURE_SERVER = "https://www.google.com/recaptcha/api";
   const RECAPTCHA_VERIFY_SERVER = "api-verify.recaptcha.net";

   public function __construct($subject, $config)
   {
      parent::__construct($subject, $config);
      $this->loadLanguage();
   }

   /**
    * Initialise the captcha
    *
    * @param   string   $id   The id of the field.
    *
    * @return   Boolean   True on success, false otherwise
    *
    * @since  2.5
    */
   public function onInit($id)
   {
      // Initialise variables
      $lang      = $this->_getLanguage();
      $pubkey      = $this->params->get('public_key', '');
      $theme      = $this->params->get('theme', 'clean');

      if ($pubkey == null || $pubkey == '')
      {
         throw new Exception(JText::_('PLG_RECAPTCHA_ERROR_NO_PUBLIC_KEY'));
      }

      $server = self::RECAPTCHA_API_SERVER;
      if (JBrowser::getInstance()->isSSLConnection())
      {
         $server = self::RECAPTCHA_API_SECURE_SERVER;
      }

      JHtml::_('script', $server.'/js/recaptcha_ajax.js');
      $document = JFactory::getDocument();
      $document->addScriptDeclaration('window.addEvent('domready', function() {
         Recaptcha.create("'.$pubkey.'", "dynamic_recaptcha_1", {theme: "'.$theme.'",'.$lang.'tabindex: 0});});'
      );

      return true;
   }

Create a free my code stock.com account now.

my code stok.com is a free service, which allows you to save and manage code snippes of any kind and programming language. We provide many advantages for your daily work with code-snippets, also for your teamwork. Give it a try!

Find out more and register now

You can customize the height of iFrame-Codes as needed! You can find more infos in our API Reference for iframe Embeds.