Advertisement
Guest User

html stuff

a guest
Sep 21st, 2018
114
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.19 KB | None | 0 0
  1. <!doctype html>
  2. <html>
  3.  
  4. <head>
  5. <title>Flask Message flashing</title>
  6. </head>
  7. <body>
  8.  
  9. {% with messages = get_flashed_messages() %}
  10. {% if messages %}
  11. <ul>
  12. {% for message in messages %}
  13. <li<{{ message }}</li>
  14. {% endfor %}
  15. </ul>
  16. {% endif %}
  17. {% endwith %}
  18.  
  19. <h1>Login?</h1>
  20. <p>Do you want to <a href = "{{ url_for('login') }}">
  21. <b>log in?</b></a></p>
  22.  
  23. </body>
  24. </html>
  25.  
  26. ----------------------------------------
  27. <!doctype html>
  28. <html>
  29. <body>
  30.  
  31. <h1>Login</h1>
  32.  
  33. {% if error %}
  34. <p><strong>Error:</strong> {{ error }}
  35. {% endif %}
  36.  
  37. <form action = "" method = post>
  38. <dl>
  39. <dt>Username:</dt>
  40.  
  41. <dd>
  42. <input type = text name = username
  43. value = "{{request.form.username }}">
  44. </dd>
  45.  
  46. <dt>Password:</dt>
  47. <dd><input type = password name = password></dd>
  48. </dl>
  49. <p><input type = submit value = Login></p>
  50. </form>
  51.  
  52. </body>
  53. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement