Difference between revisions of "Gallery2:Modules:recaptcha" - Gallery Codex
Personal tools

Difference between revisions of "Gallery2:Modules:recaptcha"

From Gallery Codex

(add romanian)
Line 64: Line 64:
== This Page In Other Languages ==
== This Page In Other Languages ==
* [http://www.fatcow.com/edu/codex-gallery-bg Bulgarian]
* [http://www.fatcow.com/edu/codex-gallery-bg Bulgarian]
* [http://fotonin.com/edu/gallery2-module-recaptcha/ Romanian] (courtesy of Petry Krontory)
[[Category:Gallery 2:Modules]]
[[Category:Gallery 2:Modules]]

Revision as of 10:56, 24 May 2015


Stop Spam,

Read Books


This module is an alternative for the default captcha component.

ReCaptcha G2 module uses the reCAPTCHA API for Carnegie Mellon University.

the current v0.4 is a beta !


Protect your gallery for spam comment

and brute force attack on your login.


  • Download the module from: http://ilpleut.be/
  • Install it by
    • creating a directory called "recaptcha" under gallery/modules/
    • unzipping the contents of recaptcha.zip into that directory
  • Create your ReCAPTCHA key
  • Activate the module on your Gallery website under "Site Admin" -> "Plugins"
  • Configure the module by entering in the public and private key that you obtained when you created your ReCAPTCHA key.
  • If you have the "Captcha" plugin already installed and activated, deactivate it to avoid having both Captcha and ReCaptcha running at the same time.

if your gallery has multiple domain names, activate the plugins through each of them.


  • v0.3, initial release
  • v0.4, this version can manage a gallery with multiple domain name & bugs fix

Requested Features for Next Version

Other Requests


v0.4 Version 0.4 contains a couple of minor bugs which results in PHP notices filling the apache error log. The notices look like this :

[Sun Jun 01 17:04:40 2008] [error] [client] PHP Notice:  Use of undefined constant recaptcha - assumed 'recaptcha' in /var/www/html/gallery/modules/recaptcha/classes/ReCaptchaValidationPlugin.inc on line 75
[Sun Jun 01 17:04:40 2008] [error] [client] PHP Notice:  Undefined variable: error in /var/www/html/gallery/modules/recaptcha/classes/ReCaptchaValidationPlugin.inc on line 75

This is caused by an old array syntax which you can read about here : [1] and an undefined "$error" array.

Here is a patch that fixes these bugs :

<                               #$form[recaptcha-error] = $resp-> error;
>                               #$form['recaptcha-error'] = $resp-> error;
>                 $error = array();
<                       $form[recaptcha]=recaptcha_get_html($publickey, $error);
>                       $form['recaptcha']=recaptcha_get_html($publickey, $error);

This Page In Other Languages