Luckily there is a simple fix for this. You need to swap the order of some of the functions around in recaptcha.php and wp-plugin.php.
In both files, the function __construct block should come before the function that shares the same name as the class. For example, recaptcha.php had been looking like this:
class ReCAPTCHAPlugin extends WPPlugin
{
private $_saved_error;
private $_reCaptchaLib;
/**
* Php 4 Constructor.
*
* @param string $options_name
*/
function ReCAPTCHAPlugin($options_name) {
$args = func_get_args();
call_user_func_array(array(&$this, "__construct"), $args);
}
/**
* Php 5 Constructor.
*
* @param string $options_name
*/
function __construct($options_name) {
parent::__construct($options_name);
$this->register_default_options();
// require the recaptcha library
$this->_require_library();
// register the hooks
$this->register_actions();
$this->register_filters();
}
But will now need to look like:
class ReCAPTCHAPlugin extends WPPlugin
{
private $_saved_error;
private $_reCaptchaLib;
/**
* Php 5 Constructor.
*
* @param string $options_name
*/
function __construct($options_name) {
parent::__construct($options_name);
$this->register_default_options();
// require the recaptcha library
$this->_require_library();
// register the hooks
$this->register_actions();
$this->register_filters();
}
/**
* Php 4 Constructor.
*
* @param string $options_name
*/
function ReCAPTCHAPlugin($options_name) {
$args = func_get_args();
call_user_func_array(array(&$this, "__construct"), $args);
}
Make sure you make the same type of change to wp-plugin.php too.