You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

60 lines
2.3 KiB

10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
  1. {{template "base/head" .}}
  2. {{template "base/navbar" .}}
  3. <div class="container" id="body">
  4. <form action="/user/sign_up" method="post" class="form-horizontal card" id="login-card">
  5. {{.CsrfTokenHtml}}
  6. {{if .DisenableRegisteration}}
  7. Sorry, registeration has been disenabled, you can only get account from administrator.
  8. {{else}}
  9. {{if .IsSocialLogin}}
  10. <h3>Social login: 2nd step <small>complete information</small></h3>
  11. {{else}}
  12. <h3>Sign Up</h3>
  13. {{end}}
  14. {{template "base/alert" .}}
  15. <div class="form-group {{if .Err_UserName}}has-error has-feedback{{end}}">
  16. <label class="col-md-4 control-label">Username: </label>
  17. <div class="col-md-6">
  18. <input name="username" class="form-control" placeholder="Type your username" value="{{.username}}" required="required">
  19. </div>
  20. </div>
  21. <div class="form-group {{if .Err_Email}}has-error has-feedback{{end}}">
  22. <label class="col-md-4 control-label">Email: </label>
  23. <div class="col-md-6">
  24. <input name="email" class="form-control" placeholder="Type your e-mail address" value="{{.email}}" required="required" title="Email is not valid">
  25. </div>
  26. </div>
  27. <div class="form-group {{if .Err_Password}}has-error has-feedback{{end}}">
  28. <label class="col-md-4 control-label">Password: </label>
  29. <div class="col-md-6">
  30. <input name="passwd" type="password" class="form-control" placeholder="Type your password" required="required" title="Password must contain at least 6 characters">
  31. </div>
  32. </div>
  33. <div class="form-group {{if .Err_RetypePasswd}}has-error has-feedback{{end}}">
  34. <label class="col-md-4 control-label">Re-type: </label>
  35. <div class="col-md-6">
  36. <input name="retypepasswd" type="password" class="form-control" placeholder="Re-type your password" required="required" title="Re-type Password must be same to Password">
  37. </div>
  38. </div>
  39. <div class="form-group">
  40. <div class="col-md-offset-4 col-md-6">
  41. <button type="submit" class="btn btn-lg btn-primary">Create an account</button>
  42. </div>
  43. </div>
  44. <div class="form-group">
  45. <div class="col-md-offset-4 col-md-6">
  46. {{if .IsSocialLogin}}
  47. <a href="/user/login">Already have an account? Bind now!</a>
  48. {{else}}
  49. <a href="/user/login">Already have an account? Sign in now!</a>
  50. {{end}}
  51. </div>
  52. </div>
  53. {{end}}
  54. </form>
  55. </div>
  56. {{template "base/footer" .}}