equal
deleted
inserted
replaced
622 { |
622 { |
623 $subst = array( |
623 $subst = array( |
624 'username' => $session->username, |
624 'username' => $session->username, |
625 'redir_target' => $lang->get('user_login_success_body_mainpage') |
625 'redir_target' => $lang->get('user_login_success_body_mainpage') |
626 ); |
626 ); |
627 redirect( makeUrl(getConfig('main_page'), false, true), $lang->get('user_login_success_title'), $lang->get('user_login_success_body', $subst) ); |
627 redirect( makeUrl(get_main_page(), false, true), $lang->get('user_login_success_title'), $lang->get('user_login_success_body', $subst) ); |
628 } |
628 } |
629 } |
629 } |
630 else |
630 else |
631 { |
631 { |
632 if ( $result['error'] === 'valid_reset' ) |
632 if ( $result['error'] === 'valid_reset' ) |
672 } |
672 } |
673 |
673 |
674 $l = $session->logout(); |
674 $l = $session->logout(); |
675 if ( $l == 'success' ) |
675 if ( $l == 'success' ) |
676 { |
676 { |
677 $url = makeUrl(getConfig('main_page'), false, true); |
677 $url = makeUrl(get_main_page(), false, true); |
678 if ( $paths->getParam(1) ) |
678 if ( $paths->getParam(1) ) |
679 { |
679 { |
680 $pi = explode('/', $paths->getAllParams()); |
680 $pi = explode('/', $paths->getAllParams()); |
681 $pi = implode('/', array_values(array_slice($pi, 1))); |
681 $pi = implode('/', array_values(array_slice($pi, 1))); |
682 list($pid, $ns) = RenderMan::strToPageID($pi); |
682 list($pid, $ns) = RenderMan::strToPageID($pi); |
1440 { |
1440 { |
1441 $template->header(); |
1441 $template->header(); |
1442 $ret = ( isset($_POST['return_to']) ) ? $_POST['return_to'] : $paths->getParam(0); |
1442 $ret = ( isset($_POST['return_to']) ) ? $_POST['return_to'] : $paths->getParam(0); |
1443 if ( !$ret ) |
1443 if ( !$ret ) |
1444 { |
1444 { |
1445 $ret = getConfig('main_page'); |
1445 $ret = get_main_page(); |
1446 } |
1446 } |
1447 ?> |
1447 ?> |
1448 <form action="<?php echo makeUrl($paths->page); ?>" method="post"> |
1448 <form action="<?php echo makeUrl($paths->page); ?>" method="post"> |
1449 <?php if ( !isset($_POST['themeselected']) ) { ?> |
1449 <?php if ( !isset($_POST['themeselected']) ) { ?> |
1450 <h3><?php echo $lang->get('userfuncs_changetheme_heading_theme'); ?></h3> |
1450 <h3><?php echo $lang->get('userfuncs_changetheme_heading_theme'); ?></h3> |
1663 $q = $db->sql_query('UPDATE '.table_prefix.'users SET password=\'' . $encpass . '\',temp_password=\'\',temp_password_time=0 WHERE user_id='.$user_id.';'); |
1663 $q = $db->sql_query('UPDATE '.table_prefix.'users SET password=\'' . $encpass . '\',temp_password=\'\',temp_password_time=0 WHERE user_id='.$user_id.';'); |
1664 |
1664 |
1665 if($q) |
1665 if($q) |
1666 { |
1666 { |
1667 $session->login_without_crypto($row['username'], $data); |
1667 $session->login_without_crypto($row['username'], $data); |
1668 echo '<p>' . $lang->get('userfuncs_passreset_stage2_success', array('url_mainpage' => makeUrl(getConfig('main_page')))) . '</p>'; |
1668 echo '<p>' . $lang->get('userfuncs_passreset_stage2_success', array('url_mainpage' => makeUrl(get_main_page()))) . '</p>'; |
1669 } |
1669 } |
1670 else |
1670 else |
1671 { |
1671 { |
1672 echo $db->get_error(); |
1672 echo $db->get_error(); |
1673 } |
1673 } |