From 8290cdb7e734679f093f100a23d161e65eba0bfb Mon Sep 17 00:00:00 2001 From: Marc Alexander Date: Sun, 13 Oct 2024 11:04:59 +0200 Subject: [PATCH] [ticket/17413] Make turnstile captcha work on registration page PHPBB-17413 --- .../adm/style/captcha_turnstile_acp_demo.html | 2 +- phpBB/language/en/captcha_turnstile.php | 13 +- phpBB/phpbb/captcha/plugins/base.php | 19 +++ .../phpbb/captcha/plugins/legacy_wrapper.php | 8 ++ .../captcha/plugins/plugin_interface.php | 7 + phpBB/phpbb/captcha/plugins/turnstile.php | 123 ++++++++++-------- .../prosilver/template/captcha_turnstile.html | 12 ++ 7 files changed, 127 insertions(+), 57 deletions(-) create mode 100644 phpBB/styles/prosilver/template/captcha_turnstile.html diff --git a/phpBB/adm/style/captcha_turnstile_acp_demo.html b/phpBB/adm/style/captcha_turnstile_acp_demo.html index 5d21532783..348e96967a 100644 --- a/phpBB/adm/style/captcha_turnstile_acp_demo.html +++ b/phpBB/adm/style/captcha_turnstile_acp_demo.html @@ -1,7 +1,7 @@
-{% INCLUDEJS 'https://challenges.cloudflare.com/turnstile/v0/api.js' %} +{% INCLUDEJS U_TURNSTILE_SCRIPT %} + + {# The cf-turnstile class is used in JavaScript #} +
+{% else %} + {{ lang('CAPTCHA_TURNSTILE_NOT_AVAILABLE') }} +{% endif %}