From f671d7559aee3c863b30a733331409a10db2c4dc Mon Sep 17 00:00:00 2001 From: mrgoldy Date: Wed, 22 Apr 2020 20:20:23 +0200 Subject: [PATCH] [ticket/15937] ReCaptcha language fixes (sprintf and https links) PHPBB3-15937 --- phpBB/language/en/captcha_recaptcha.php | 10 +++++----- phpBB/phpbb/captcha/plugins/recaptcha_v3.php | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/phpBB/language/en/captcha_recaptcha.php b/phpBB/language/en/captcha_recaptcha.php index 10eace67df..60d61cc2c8 100644 --- a/phpBB/language/en/captcha_recaptcha.php +++ b/phpBB/language/en/captcha_recaptcha.php @@ -46,15 +46,15 @@ $lang = array_merge($lang, array( 'RECAPTCHA_INCORRECT' => 'The solution you provided was incorrect', 'RECAPTCHA_NOSCRIPT' => 'Please enable JavaScript in your browser to load the challenge.', - 'RECAPTCHA_NOT_AVAILABLE' => 'In order to use reCaptcha, you must create an account on www.google.com/recaptcha.', + 'RECAPTCHA_NOT_AVAILABLE' => 'In order to use reCaptcha, you must create an account on www.google.com/recaptcha.', 'RECAPTCHA_INVISIBLE' => 'This CAPTCHA is actually invisible. To verify that it works, a small icon should appear in right bottom corner of this page.', 'RECAPTCHA_PUBLIC' => 'Site key', - 'RECAPTCHA_PUBLIC_EXPLAIN' => 'Your site reCAPTCHA key. Keys can be obtained on www.google.com/recaptcha. Please, use reCAPTCHA v2 > Invisible reCAPTCHA badge type.', - 'RECAPTCHA_V3_PUBLIC_EXPLAIN' => 'Your site reCAPTCHA key. Keys can be obtained on www.google.com/recaptcha. Please, use reCAPTCHA v3.', + 'RECAPTCHA_PUBLIC_EXPLAIN' => 'Your site reCAPTCHA key. Keys can be obtained on www.google.com/recaptcha. Please, use reCAPTCHA v2 > Invisible reCAPTCHA badge type.', + 'RECAPTCHA_V3_PUBLIC_EXPLAIN' => 'Your site reCAPTCHA key. Keys can be obtained on www.google.com/recaptcha. Please, use reCAPTCHA v3.', 'RECAPTCHA_PRIVATE' => 'Secret key', - 'RECAPTCHA_PRIVATE_EXPLAIN' => 'Your secret reCAPTCHA key. Keys can be obtained on www.google.com/recaptcha. Please, use reCAPTCHA v2 > Invisible reCAPTCHA badge type.', - 'RECAPTCHA_V3_PRIVATE_EXPLAIN' => 'Your secret reCAPTCHA key. Keys can be obtained on www.google.com/recaptcha. Please, use reCAPTCHA v3.', + 'RECAPTCHA_PRIVATE_EXPLAIN' => 'Your secret reCAPTCHA key. Keys can be obtained on www.google.com/recaptcha. Please, use reCAPTCHA v2 > Invisible reCAPTCHA badge type.', + 'RECAPTCHA_V3_PRIVATE_EXPLAIN' => 'Your secret reCAPTCHA key. Keys can be obtained on www.google.com/recaptcha. Please, use reCAPTCHA v3.', 'RECAPTCHA_V3_DOMAIN' => 'Request domain', 'RECAPTCHA_V3_DOMAIN_EXPLAIN' => 'The domain to fetch the script from and to use when verifying the request.
Use recaptcha.net when google.com is not accessible.', diff --git a/phpBB/phpbb/captcha/plugins/recaptcha_v3.php b/phpBB/phpbb/captcha/plugins/recaptcha_v3.php index ceea796d96..7505419a31 100644 --- a/phpBB/phpbb/captcha/plugins/recaptcha_v3.php +++ b/phpBB/phpbb/captcha/plugins/recaptcha_v3.php @@ -262,7 +262,7 @@ class recaptcha_v3 extends captcha_abstract 'RECAPTCHA_ACTION' => self::$actions[$this->type] ?? reset(self::$actions), 'RECAPTCHA_KEY' => $config['recaptcha_v3_key'] ?? '', - 'U_RECAPTCHA_SCRIPT' => sprintf('//%s/recaptcha/api.js?render=%s', $domain, $render), + 'U_RECAPTCHA_SCRIPT' => sprintf('//%1$s/recaptcha/api.js?render=%2$s', $domain, $render), 'S_CONFIRM_CODE' => true, 'S_RECAPTCHA_AVAILABLE' => $this->is_available(),