\n"; if (!empty($_POST[submit])) { $form_new_passwd1 = $_POST[form_new_passwd1]; $form_new_passwd2 = $_POST[form_new_passwd2]; if (empty($form_new_passwd1) or empty($form_new_passwd2)) { print "

\n"; print "You will need to fill all fields!\n"; print_footer(); exit; } if ($form_new_passwd1 != $form_new_passwd2) { print "

\n"; print "The new passwords that you supplied don't match!\n"; print_footer(); exit; } $new_passwd = md5crypt($form_new_passwd1); $result = db_query ("UPDATE mailbox SET password='$new_passwd',change_date=NOW() WHERE username='$username' AND domain='$sessid[domain]'"); if ($result[rows] == 1) { print "The password has been updated!\n"; print "

\n"; print "Go Back\n"; print_footer(); exit; } else { print "

\n"; print "Unable to update your password!\n"; print_footer(); exit; } } ?> Change password.

Login:
New Password:
New Password (again):