. */ /** * Note to anyone feeling the need to edit this file... * You MUST declare $db as global inside your functions in order access MySQL from here. */ function changePassword(){ echo ""; global $db; if(isset($_POST['processed'])) { $password = $_POST['password']; $confirm = $_POST['confirm']; if($password != $confirm){ ReportError("The passwords you entered did not match."); PageRedirect(3, "?op=settings&change=password"); return; }else if(strlen($password)<6){ ReportError("The password you entered is less than 6 characters."); PageRedirect(3, "?op=settings&change=password"); return; } $newpassword = crypt(md5($password),'iamnotadirtywhorebitch'); $username = $_SESSION['username']; $db->Query("UPDATE `bayonet_users` SET `password` = '$newpassword' WHERE `username` = '$username' LIMIT 1"); echo "Your password has successfully been changed."; PageRedirect(3,"?op=settings"); return; } ?>

Change Your Password

Password:
Password Strength:
Minimum of 6 Characters
Confirm Password: