aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/captcha/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB/includes/captcha/plugins')
-rw-r--r--phpBB/includes/captcha/plugins/captcha_abstract.php26
-rw-r--r--phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php2
-rw-r--r--phpBB/includes/captcha/plugins/phpbb_recaptcha_plugin.php6
3 files changed, 14 insertions, 20 deletions
diff --git a/phpBB/includes/captcha/plugins/captcha_abstract.php b/phpBB/includes/captcha/plugins/captcha_abstract.php
index 1446df9874..1682293c02 100644
--- a/phpBB/includes/captcha/plugins/captcha_abstract.php
+++ b/phpBB/includes/captcha/plugins/captcha_abstract.php
@@ -85,29 +85,27 @@ class phpbb_default_captcha
function get_template()
{
global $config, $user, $template, $phpEx, $phpbb_root_path;
-
- $template->set_filenames(array(
- 'captcha' => 'captcha_default.html')
- );
-
+
+ $link = append_sid($phpbb_root_path . 'ucp.' . $phpEx . '?mode=confirm&confirm_id=' . $this->confirm_id . '&type=' . $this->type);
+ $explain = ($this->type != CONFIRM_POST) ? sprintf($user->lang['CONFIRM_EXPLAIN'], '<a href="mailto:' . htmlspecialchars($config['board_contact']) . '">', '</a>') : $user->lang['POST_CONFIRM_EXPLAIN'];
+
$template->assign_vars(array(
- 'CONFIRM_IMAGE' => append_sid($phpbb_root_path . 'ucp.' . $phpEx . '?mode=confirm&amp;confirm_id=' . $this->confirm_id . '&amp;type=' . $this->type),
+ 'CONFIRM_IMAGE_LINK' => $link,
+ 'CONFIRM_IMAGE' => '<img src="'. $link . '" />',
+ 'CONFIRM_IMG' => '<img src="'. $link . '" />',
'CONFIRM_ID' => $this->confirm_id,
- 'S_REFRESH' => (bool) $config['confirm_refresh'],
-
+ 'S_CONFIRM_CODE' => true,
+ 'S_CONFIRM_REFRESH' => ($config['enable_confirm'] && $config['confirm_refresh'] && $this->type == CONFIRM_REG) ? true : false,
+ 'L_CONFIRM_EXPLAIN' => $explain,
));
- return $template->assign_display('captcha');
+ return 'captcha_default.html';
}
function get_demo_template($id)
{
global $config, $user, $template, $phpbb_admin_path, $phpEx;
- $template->set_filenames(array(
- 'captcha_demo' => 'captcha_default_acp_demo.html')
- );
-
$variables = '';
if (is_array($this->captcha_vars))
@@ -124,7 +122,7 @@ class phpbb_default_captcha
'CONFIRM_ID' => $this->confirm_id,
));
- return $template->assign_display('captcha_demo');
+ return 'captcha_default_acp_demo.html';
}
function get_hidden_fields()
diff --git a/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php b/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php
index 108e8f686e..ab71da10d7 100644
--- a/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php
+++ b/phpBB/includes/captcha/plugins/phpbb_captcha_gd_plugin.php
@@ -34,7 +34,7 @@ class phpbb_captcha_gd extends phpbb_default_captcha
'captcha_gd_x_grid' => 'CAPTCHA_GD_X_GRID',
'captcha_gd_y_grid' => 'CAPTCHA_GD_Y_GRID',
'captcha_gd_foreground_noise' => 'CAPTCHA_GD_FOREGROUND_NOISE',
- 'captcha_gd' => 'CAPTCHA_GD_PREVIEWED',
+// 'captcha_gd' => 'CAPTCHA_GD_PREVIEWED',
'captcha_gd_wave' => 'CAPTCHA_GD_WAVE',
'captcha_gd_3d_noise' => 'CAPTCHA_GD_3D_NOISE',
'captcha_gd_fonts' => 'CAPTCHA_GD_FONTS',
diff --git a/phpBB/includes/captcha/plugins/phpbb_recaptcha_plugin.php b/phpBB/includes/captcha/plugins/phpbb_recaptcha_plugin.php
index 2a20b4b78d..bd8fbce0fa 100644
--- a/phpBB/includes/captcha/plugins/phpbb_recaptcha_plugin.php
+++ b/phpBB/includes/captcha/plugins/phpbb_recaptcha_plugin.php
@@ -128,10 +128,6 @@ class phpbb_recaptcha extends phpbb_default_captcha
{
global $config, $user, $template;
- $template->set_filenames(array(
- 'captcha' => 'captcha_recaptcha.html')
- );
-
$template->assign_vars(array(
'RECAPTCHA_SERVER' => $this->recaptcha_server,
'RECAPTCHA_PUBKEY' => isset($config['recaptcha_pubkey']) ? $config['recaptcha_pubkey'] : '',
@@ -139,7 +135,7 @@ class phpbb_recaptcha extends phpbb_default_captcha
'S_RECAPTCHA_AVAILABLE' => $this->is_available(),
));
- return $template->assign_display('captcha');
+ return 'captcha_recaptcha.html';
}
function get_demo_template($id)