aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes
diff options
context:
space:
mode:
authorHenry Sudhof <kellanved@phpbb.com>2009-06-26 20:58:36 +0000
committerHenry Sudhof <kellanved@phpbb.com>2009-06-26 20:58:36 +0000
commit076067f85649e53c77aceddf68b469ef59a294ca (patch)
tree40446a41f337a0d4fe2e55ac4027b3cdf782d79b /phpBB/includes
parentd61574a61e4b46f8c7ad0e75f0e2261ab8405670 (diff)
downloadforums-076067f85649e53c77aceddf68b469ef59a294ca.tar
forums-076067f85649e53c77aceddf68b469ef59a294ca.tar.gz
forums-076067f85649e53c77aceddf68b469ef59a294ca.tar.bz2
forums-076067f85649e53c77aceddf68b469ef59a294ca.tar.xz
forums-076067f85649e53c77aceddf68b469ef59a294ca.zip
Okay, okay, I see the issue. I'll revisit this tomorrow.
git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@9695 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes')
-rw-r--r--phpBB/includes/captcha/plugins/captcha_abstract.php11
-rw-r--r--phpBB/includes/ucp/ucp_register.php4
2 files changed, 5 insertions, 10 deletions
diff --git a/phpBB/includes/captcha/plugins/captcha_abstract.php b/phpBB/includes/captcha/plugins/captcha_abstract.php
index e23cfd0de0..c6de2ff887 100644
--- a/phpBB/includes/captcha/plugins/captcha_abstract.php
+++ b/phpBB/includes/captcha/plugins/captcha_abstract.php
@@ -38,13 +38,12 @@ class phpbb_default_captcha
global $config, $db, $user;
// read input
- $this->confirm_id = request_var('confirm_id', '');
$this->confirm_code = request_var('confirm_code', '');
$refresh = request_var('refresh_vc', false) && $config['confirm_refresh'];
$this->type = (int) $type;
- if (!strlen($this->confirm_id) || !$this->load_code())
+ if (!$this->load_code())
{
// we have no confirm ID, better get ready to display something
$this->generate_code();
@@ -205,6 +204,7 @@ class phpbb_default_captcha
{
// okay, incorrect answer. Let's ask a new question.
$this->new_attempt();
+ $this->solved = false;
return $error;
}
else
@@ -277,7 +277,6 @@ class phpbb_default_captcha
'seed' => (int) $this->seed)) . '
, attempts = attempts + 1
WHERE
- confirm_id = \'' . $db->sql_escape($this->confirm_id) . '\' AND
session_id = \'' . $db->sql_escape($user->session_id) . '\'';
$db->sql_query($sql);
}
@@ -289,10 +288,9 @@ class phpbb_default_captcha
{
global $db, $user;
- $sql = 'SELECT code, seed, attempts
+ $sql = 'SELECT code, confirm_id, seed, attempts
FROM ' . CONFIRM_TABLE . "
- WHERE confirm_id = '" . $db->sql_escape($this->confirm_id) . "'
- AND session_id = '" . $db->sql_escape($user->session_id) . "'
+ WHERE session_id = '" . $db->sql_escape($user->session_id) . "'
AND confirm_type = " . $this->type;
$result = $db->sql_query($sql);
$row = $db->sql_fetchrow($result);
@@ -300,6 +298,7 @@ class phpbb_default_captcha
if ($row)
{
+ $this->confirm_id = $row['confirm_id'];
$this->code = $row['code'];
$this->seed = $row['seed'];
$this->attempts = $row['attempts'];
diff --git a/phpBB/includes/ucp/ucp_register.php b/phpBB/includes/ucp/ucp_register.php
index ef6b076ebc..a802a35b87 100644
--- a/phpBB/includes/ucp/ucp_register.php
+++ b/phpBB/includes/ucp/ucp_register.php
@@ -103,10 +103,6 @@ class ucp_register
'tz' => request_var('tz', (float) $config['board_timezone']),
));
- if ($config['enable_confirm'])
- {
- $s_hidden_fields = array_merge($s_hidden_fields, $captcha->get_hidden_fields());
- }
}
// Checking amount of available languages