From ff60fc9c1e6565eb12f4c8f4591c5cafc012bfb7 Mon Sep 17 00:00:00 2001 From: Henry Sudhof Date: Mon, 20 Jul 2009 10:22:13 +0000 Subject: [PATCH] fixing back links git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@9801 89ea8834-ac86-4346-8a33-228a782c2dd0 --- .../captcha/plugins/phpbb_captcha_qa_plugin.php | 12 ++++++++---- .../captcha/plugins/phpbb_recaptcha_plugin.php | 4 ++-- .../en/{recaptcha.php => captcha_recaptcha.php} | 0 3 files changed, 10 insertions(+), 6 deletions(-) rename phpBB/language/en/{recaptcha.php => captcha_recaptcha.php} (100%) diff --git a/phpBB/includes/captcha/plugins/phpbb_captcha_qa_plugin.php b/phpBB/includes/captcha/plugins/phpbb_captcha_qa_plugin.php index 1992117e09..d6ef8f50b1 100644 --- a/phpBB/includes/captcha/plugins/phpbb_captcha_qa_plugin.php +++ b/phpBB/includes/captcha/plugins/phpbb_captcha_qa_plugin.php @@ -474,6 +474,7 @@ class phpbb_captcha_qa $question_id = request_var('question_id', 0); $action = request_var('action', ''); + $list_url = $module->u_action . "&configure=1&select_captcha=" . $this->get_class_name(); $template->assign_vars(array( 'U_ACTION' => $module->u_action, @@ -490,7 +491,7 @@ class phpbb_captcha_qa if (confirm_box(true)) { $this->acp_delete_question($question_id); - trigger_error($user->lang['QUESTION_DELETED'] . adm_back_link($module->u_action)); + trigger_error($user->lang['QUESTION_DELETED'] . adm_back_link($list_url)); } else { @@ -520,6 +521,9 @@ class phpbb_captcha_qa )); } + $template->assign_vars(array( + 'U_LIST' => $list_url, + )); if ($question_id) { if ($question = $this->acp_get_question_data($question_id)) @@ -534,7 +538,7 @@ class phpbb_captcha_qa } else { - trigger_error($user->lang['FORM_INVALID'] . adm_back_link($module->u_action)); + trigger_error($user->lang['FORM_INVALID'] . adm_back_link($list_url)); } } else @@ -568,12 +572,12 @@ class phpbb_captcha_qa $this->acp_add_question($data); } - trigger_error($user->lang['CONFIG_UPDATED'] . adm_back_link($module->u_action . "&configure=1&select_captcha=" . $this->get_class_name())); + trigger_error($user->lang['CONFIG_UPDATED'] . adm_back_link($list_url)); } } else if ($submit) { - trigger_error($user->lang['FORM_INVALID'] . adm_back_link($module->u_action)); + trigger_error($user->lang['FORM_INVALID'] . adm_back_link($list_url)); } } } diff --git a/phpBB/includes/captcha/plugins/phpbb_recaptcha_plugin.php b/phpBB/includes/captcha/plugins/phpbb_recaptcha_plugin.php index 41ce242e91..f148b12656 100644 --- a/phpBB/includes/captcha/plugins/phpbb_recaptcha_plugin.php +++ b/phpBB/includes/captcha/plugins/phpbb_recaptcha_plugin.php @@ -36,7 +36,7 @@ class phpbb_recaptcha extends phpbb_default_captcha { global $config, $db, $user; - $user->add_lang('recaptcha'); + $user->add_lang('captcha_recaptcha'); parent::init($type); $this->challenge = request_var('recaptcha_challenge_field', ''); $this->response = request_var('recaptcha_response_field', ''); @@ -51,7 +51,7 @@ class phpbb_recaptcha extends phpbb_default_captcha function is_available() { global $config, $user; - $user->add_lang('recaptcha'); + $user->add_lang('captcha_recaptcha'); return (isset($config['recaptcha_pubkey']) && !empty($config['recaptcha_pubkey'])); } diff --git a/phpBB/language/en/recaptcha.php b/phpBB/language/en/captcha_recaptcha.php similarity index 100% rename from phpBB/language/en/recaptcha.php rename to phpBB/language/en/captcha_recaptcha.php