jinja base template sample

Solutions on MaxInterview for jinja base template sample by the best coders in the world

showing results for - "jinja base template sample"
Janette
10 May 2017
1{% extends "layout.html" %}
2{% block title %}Index{% endblock %}
3{% block head %}
4  {{ super() }}
5  <style type="text/css">
6    .important { color: #336699; }
7  </style>
8{% endblock %}
9{% block content %}
10  <h1>Index</h1>
11  <p class="important">
12    Welcome on my awesome homepage.
13{% endblock %}
14
Maite
14 Feb 2020
1<!doctype html>
2<html>
3  <head>
4    {% block head %}
5    <link rel="stylesheet" href="{{ url_for('static', filename='style.css') }}">
6    <title>{% block title %}{% endblock %} - My Webpage</title>
7    {% endblock %}
8  </head>
9  <body>
10    <div id="content">{% block content %}{% endblock %}</div>
11    <div id="footer">
12      {% block footer %}
13      © Copyright 2010 by <a href="http://domain.invalid/">you</a>.
14      {% endblock %}
15    </div>
16  </body>
17</html>
18