Display blog article on landing page

This commit is contained in:
2025-12-30 21:37:15 +01:00
parent 9baeb3736b
commit d6b4d64390
4 changed files with 65 additions and 3 deletions

View File

@@ -41,8 +41,27 @@
<p class="center"><a href="{{ url_for('loginlogout.lost_password') }}"> Mouarf j'ai perdu mon mot de passe </a> </p>
<button class="btn btn-default btn-primary" type="submit"> Login </button>
</form>
<h2> Les derniers articles de blog sur le serveur </h2>
<div class="list-articles" >
{% for article in list_posts %}
<article>
<header>
<h3> {{ article.title }} </h3>
<h5> par <a href="/blog/{{ article.author }}/">/{{ article.author }}</a> </h5>
<br/>
<small> Créé le : {{ article.creation_date }} </small> <br/>
{% if article.last_updated %}
<small> Modifié le : {{ article.last_updated }}</small><br/>
{% endif %}
</header>
<div class="subtitle">
<p> {{ article.subtitle }} </p>
</div>
<footer><a href="/blog//public_unified/{{ article.author }}/{{ article.title }}"> <button> Lire la suite </button> </a></footer>
</article>
{% endfor %}
{% endblock %}
</main>