diff options
| author | Mitsuo Tokumori <[email protected]> | 2023-10-27 19:56:12 -0500 |
|---|---|---|
| committer | Mitsuo Tokumori <[email protected]> | 2023-10-27 19:56:12 -0500 |
| commit | f59b3ba871f1086beb147c2de46f0cd60ce070c2 (patch) | |
| tree | d9064e0ee41d58437f42c7e7c2a636000f50e18f /flaskr/templates/base.html | |
| parent | 87e6ced8ecd0ba54af1f67319fccf96c13ba6261 (diff) | |
| download | ustayml-f59b3ba871f1086beb147c2de46f0cd60ce070c2.tar.gz ustayml-f59b3ba871f1086beb147c2de46f0cd60ce070c2.tar.bz2 ustayml-f59b3ba871f1086beb147c2de46f0cd60ce070c2.zip | |
Add auth view and static files
Diffstat (limited to 'flaskr/templates/base.html')
| -rw-r--r-- | flaskr/templates/base.html | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/flaskr/templates/base.html b/flaskr/templates/base.html new file mode 100644 index 0000000..6ea4864 --- /dev/null +++ b/flaskr/templates/base.html @@ -0,0 +1,25 @@ +<!doctype html> +<title>{% block title %}{% endblock %} - Flaskr</title> +<link rel="stylesheet" href="{{ url_for('static', filename='style.css') }}"> +<link rel="shortcut icon" href="{{ url_for('static', filename='favicon.ico') }}"> +<nav> + <h1><a href="{{ url_for('index') }}">Flaskr</a></h1> + <ul> + {% if g.user %} + <li><span>{{ g.user['username'] }}</span> + <li><a href="{{ url_for('auth.logout') }}">Log Out</a> + {% else %} + <li><a href="{{ url_for('auth.register') }}">Register</a> + <li><a href="{{ url_for('auth.login') }}">Log In</a> + {% endif %} + </ul> +</nav> +<section class="content"> + <header> + {% block header %}{% endblock %} + </header> + {% for message in get_flashed_messages() %} + <div class="flash">{{ message }}</div> + {% endfor %} + {% block content %}{% endblock %} +</section>
\ No newline at end of file |
