Thread:Extension talk:ConfirmEdit/Solution for typical problems with reCaptcha and MediaWiki 1.25

If you're updating, start with deleting whole extensions/ConfirmEdit dir and copy it from mediawiki 1.25 archive. Replacing files won't do any good.

require_once "$IP/extensions/ConfirmEdit/ConfirmEdit.php"; require_once "$IP/extensions/ConfirmEdit/ReCaptcha.php"; $wgCaptchaClass = 'ReCaptcha'; $wgReCaptchaPublicKey = 'your-public-key'; $wgReCaptchaPrivateKey = 'your-private-key';
 * 1) * Error: PHP Warning: call_user_func expects parameter 1 to be a valid callback, class 'ConfirmEditHooks' not found in /var/www/te_pl_wiki/includes/registration/ExtensionRegistry.php on line 169
 * 2) * Solution: include ConfirmEdit.php in your LocalConfig before loading a ReCaptcha.
 * 3) * Example:
 * 1) * Example:

"ExtensionFunctions": [ ],
 * 1) * Error: PHP Warning: call_user_func expects parameter 1 to be a valid callback, function 'efReCaptcha' not found or invalid function name in /var/www/bw_fr_wiki/includes/Setup.php on line 678
 * 2) * Solution: edit extensions/ConfirmEdit/ReCaptcha/extension.json and remove "efReCaptcha" from "ExtensioFunctions"
 * 3) * Example:
 * 1) * Example:

public static function onReCaptchaSetup { //error_log("cwd: ".getcwd); // to debug currect dir location in log require_once( "extensions/ConfirmEdit/ReCaptcha/recaptchalib.php" ); }
 * 1) * Error: PHP Warning: require_once(ReCaptcha/recaptchalib.php): failed to open stream: No such file or directory in /var/www/br_pl_wiki/extensions/ConfirmEdit/includes/ConfirmEditHooks.php on line 147
 * 2) * Solution: edit extensions/ConfirmEdit/includes/ConfirmEditHooks.php and edit function onReCaptchaSetup, so it can find the file.
 * 3) * Example:
 * 1) * Example: