PageRenderTime 25ms CodeModel.GetById 19ms RepoModel.GetById 0ms app.codeStats 0ms

/AnotherStartup/Account/ForgotPassword.cshtml

#
Razor | 35 lines | 34 code | 1 blank | 0 comment | 3 complexity | 9fc919dc30c14d2c96b9cc19c2e1994f MD5 | raw file
  1. @{this.Init(layout: "~/_SiteLayout.cshtml", title: "Forget Your Password?", action: Account.ForgotPassword.Init);}
  2. <form method="post" action="">
  3. <fieldset>
  4. <legend>Password Reset Instructions Form</legend>
  5. @if (!WebMail.SmtpServer.IsEmpty()) {
  6. <p>
  7. We will send password reset instructions to the email address associated with your account.
  8. </p>
  9. if (Page.IsReadonly) {
  10. <p class="message success">
  11. Instructions to reset your password have been sent to the specified email address.
  12. </p>
  13. }
  14. <ol>
  15. <li class="email">
  16. <label for="email">Email Address</label>
  17. <input type="text" id="email" name="email" title="Email address" value="@Page.Model.Email" @if(Page.IsReadonly){<text>disabled="disabled"</text>} @if(Page.Errors.Email.IsError){<text>class="error-field"</text>} />
  18. @if (Page.Errors.Email.IsError) {
  19. <label class="validation-error">@Page.Errors.Email.Message</label>
  20. }
  21. </li>
  22. </ol>
  23. <p class="form-actions">
  24. <input type="submit" value="Send Instructions" @if(Page.IsReadonly){<text>disabled="disabled"</text>}/>
  25. </p>
  26. } else {
  27. <p class="message info">
  28. Password recovery is disabled for this website because the SMTP server is
  29. not configured correctly. Please contact the owner of this site to reset
  30. your password.
  31. </p>
  32. }
  33. </fieldset>
  34. </form>