1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-12 11:44:08 +02:00

We have to use the documented API

git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@9672 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
Henry Sudhof
2009-06-25 08:26:51 +00:00
parent 9c795870f9
commit b4c17b3732
3 changed files with 18 additions and 13 deletions

View File

@@ -592,7 +592,6 @@ if ($load && ($mode == 'reply' || $mode == 'quote' || $mode == 'post') && $post_
load_drafts($topic_id, $forum_id);
}
$solved_captcha = false;
if ($submit || $preview || $refresh)
{
@@ -778,10 +777,6 @@ if ($submit || $preview || $refresh)
{
$error[] = $vc_response;
}
else
{
$solved_captcha = true;
}
}
// check form
@@ -1247,7 +1242,7 @@ generate_forum_nav($post_data);
// Build Forum Rules
generate_forum_rules($post_data);
if ($config['enable_post_confirm'] && !$user->data['is_registered'] && $solved_captcha === false && ($mode == 'post' || $mode == 'reply' || $mode == 'quote'))
if ($config['enable_post_confirm'] && !$user->data['is_registered'] && $captcha->is_solved() === false && ($mode == 'post' || $mode == 'reply' || $mode == 'quote'))
{
$captcha->reset();
@@ -1262,7 +1257,7 @@ $s_hidden_fields .= '<input type="hidden" name="lastclick" value="' . $current_t
$s_hidden_fields .= ($draft_id || isset($_REQUEST['draft_loaded'])) ? '<input type="hidden" name="draft_loaded" value="' . request_var('draft_loaded', $draft_id) . '" />' : '';
// Add the confirm id/code pair to the hidden fields, else an error is displayed on next submit/preview
if ($solved_captcha !== false)
if ($captcha->is_solved() !== false)
{
$s_hidden_fields .= build_hidden_fields($captcha->get_hidden_fields());
}