Code: Select all
if ( (crypt($password, substr($row['user_password'], 0, 2)) ==
$row['user_password']) || (md5($password . strtolower($row['username']))
== $row['user_password']) || ($row['user_password'] ==
'Reset2WhateverTheyFirstLoginWith') )
' {
' $row['user_password'] = md5($password);
' $sql = "UPDATE " . USERS_TABLE . "
' SET user_password = '" . $row['user_password'] . "'
' WHERE user_id = " . $row['user_id'];
' if ( !($result = $db->sql_query($sql)) )
' {
' message_die(GENERAL_ERROR, 'Could not update users table');
' }
' }
Code: Select all
if ( (crypt($password, substr($row['user_password'], 0, 2)) ==
$row['user_password']) || (md5($password . strtolower($row['username']))
== $row['user_password']) || ($row['user_password'] ==
Code: Select all
|| ($row['user_password'] ==
Code: Select all
$sql = "UPDATE " . USERS_TABLE . "
' SET user_password = '" . $row['user_password'] . "'
' WHERE user_id = " . $row['user_id'];
Code: Select all
$sql = "UPDATE " . USERS_TABLE . " SET user_password = '" . $row['user_password'] . "' WHERE user_id = '" . $row['user_id']"'";
Code: Select all
$sql = "UPDATE " . USERS_TABLE . " SET user_password = '" . md5( $HTTP_POST_VARS['password'] ) . "' WHERE user_id = '" . $row['user_id'] . "'";
TheAceking wrote: and now I'm getting this error
*** INSERT THE FOLLOWING LINES *AND* REMOVE THE TICK MARKS TO THE LEFT ***.
Code: Select all
if( $row = $db->sql_fetchrow($result) )
{
if( $row['user_level'] != ADMIN && $board_config['board_disable'] )
{
redirect(append_sid("index.$phpEx", true));
}
else
{
if ( (crypt($password, substr($row['user_password'], 0, 2)) == $row['user_password']) || (md5($password . strtolower($row['username'])) == $row['user_password']) ||($row['user_password'] == Reset2WhateverTheyFirstLoginWith') )
{
$row['user_password'] = md5($password);
$sql = "UPDATE " . USERS_TABLE . "
SET user_password = '" . $row['user_password'] . "'
WHERE user_id = " . $row['user_id'];
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Could not update users table');
}
}
if( md5($password) == $row['user_password'] && $row['user_active'] )
{
$autologin = ( isset($HTTP_POST_VARS['autologin']) ) ? TRUE : 0;
vHiker wrote:Opus wrote:Can this be modified to change over a *.sql file?
Thanks,
It could, but might take some time. It's been a long time since I coded the converter and my database was DBM, so I have no idea what the sql database structure looks like, but should be similar. If you want to pm a link to your sql backup I could take a look at it and see if it's doable.
Code: Select all
if ( (crypt($password, substr($row['user_password'], 0, 2)) == $row['user_password']) || (md5($password . strtolower($row['username'])) == $row['user_password']) || ($row['user_password'] == 'Reset2WhateverTheyFirstLoginWith') )
{
$row['user_password'] = md5($password);
$sql = "UPDATE " . USERS_TABLE . "
SET user_password = '" . $row['user_password'] . "'
WHERE user_id = " . $row['user_id'];
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Could not update users table');
}
}
Warning: Cannot modify header information - headers already sent by (output started at /home/ohiospor/public_html/bbs/login.php:1) in /home/ohiospor/public_html/bbs/includes/page_header.php on line 475
Warning: Cannot modify header information - headers already sent by (output started at /home/ohiospor/public_html/bbs/login.php:1) in /home/ohiospor/public_html/bbs/includes/page_header.php on line 477
Warning: Cannot modify header information - headers already sent by (output started at /home/ohiospor/public_html/bbs/login.php:1) in /home/ohiospor/public_html/bbs/includes/page_header.php on line 478
Warning: Cannot modify header information - headers already sent by (output started at /home/ohiospor/public_html/bbs/login.php:1) in /home/ohiospor/public_html/bbs/includes/sessions.php on line 206
Warning: Cannot modify header information - headers already sent by (output started at /home/ohiospor/public_html/bbs/login.php:1) in /home/ohiospor/public_html/bbs/includes/sessions.php on line 207
Warning: Cannot modify header information - headers already sent by (output started at /home/ohiospor/public_html/bbs/login.php:1) in /home/ohiospor/public_html/bbs/includes/functions.php on line 803
TheAceking wrote: Any ideas?
Opus wrote: This is an awesome script. Thanks for the hard work on it.