mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-21 10:48:59 +00:00
Send new password + old password check stuff ... this time I'm fairly confident it works
git-svn-id: file:///svn/phpbb/trunk@1157 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
eaec818287
commit
61288e89d9
1 changed files with 2 additions and 3 deletions
|
@ -539,8 +539,6 @@ if( isset($HTTP_GET_VARS['mode']) || isset($HTTP_POST_VARS['mode']) )
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$password = md5($password);
|
|
||||||
|
|
||||||
if( $mode == "editprofile" )
|
if( $mode == "editprofile" )
|
||||||
{
|
{
|
||||||
$sql = "SELECT user_password
|
$sql = "SELECT user_password
|
||||||
|
@ -550,7 +548,7 @@ if( isset($HTTP_GET_VARS['mode']) || isset($HTTP_POST_VARS['mode']) )
|
||||||
{
|
{
|
||||||
$row = $db->sql_fetchrow($result);
|
$row = $db->sql_fetchrow($result);
|
||||||
|
|
||||||
if( $row['user_password'] != $password_current )
|
if( $row['user_password'] != md5($password_current) )
|
||||||
{
|
{
|
||||||
$error = TRUE;
|
$error = TRUE;
|
||||||
$error_msg = $lang['Current_password_mismatch'];
|
$error_msg = $lang['Current_password_mismatch'];
|
||||||
|
@ -564,6 +562,7 @@ if( isset($HTTP_GET_VARS['mode']) || isset($HTTP_POST_VARS['mode']) )
|
||||||
|
|
||||||
if( !$error )
|
if( !$error )
|
||||||
{
|
{
|
||||||
|
$password = md5($password);
|
||||||
$passwd_sql = "user_password = '$password', ";
|
$passwd_sql = "user_password = '$password', ";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue