public ActionResult ChangePassword(PasswordChange model) { var User = GetPlayer().User; model.databasePassword = User.Password; if (ModelState.IsValid) { //update the users password User.Updated = SystemDate.Current(); User.Password = model.newPassword.ToLower(); return Redirect("/Player"); } else { return View(model); } }
public ActionResult ChangePassword() { var model = new PasswordChange(); return View(model); }