AN-net, could I please get a code revison for this piece of code? I'm using v3.0 and my code is a little different in profile.php
According to the directions I should look for:
Code:
~~~~~~~~~~~~~~~~~~~~~~
Find:
if ($newpassword OR $newemail)
{
$DB_site->query("UPDATE " . TABLE_PREFIX . "user SET $newpassword $newemail usergroupid = " . intval($bbuserinfo['usergroupid']) . " WHERE userid = $bbuserinfo[userid]");
}
But the closest thing I have is this:
Code:
if (!empty($newpassword))
{
// insert record into password history
$DB_site->query("INSERT INTO " . TABLE_PREFIX . "passwordhistory (userid, password, passworddate) VALUES ($bbuserinfo[userid], '" . addslashes($newpassword) . "', NOW())");
$newpassword = "password = '" . addslashes($newpassword) . "', passworddate = NOW(),";
} else {
$newpassword = '';
}
$DB_site->query("UPDATE " . TABLE_PREFIX . "user SET $newpassword $newemail usergroupid = " . intval($bbuserinfo['usergroupid']) . " WHERE userid='$bbuserinfo[userid]'");
if ($newemailaddress)
{
$url = "usercp.php?$session[sessionurl]";
eval(print_standard_redirect('redirect_updatethanks_newemail'));
}
else
{
$url = "usercp.php?$session[sessionurl]";
eval(print_standard_redirect('redirect_updatethanks'));
}
}
Can you provide me with a revised bit of code for this step in your directions?
Thank you very much!