fix: Les urls des images contenu dans les articles

This commit is contained in:
Simon 2021-06-10 14:16:30 +02:00
parent de06c4700b
commit 3746357479
1 changed files with 1 additions and 1 deletions

View File

@ -1,5 +1,5 @@
{{/*
S'il n'y a pas de / dans l'url d'une image alors on ajoute le path de l'article
*/}}
{{ $path := cond (in .Destination "/") .Destination (path.Join "/" .Page.File.Dir .Destination) }}
{{ $path := cond (in .Destination "/") .Destination (path.Join "/" .Page.RelPermalink .Destination) }}
<img src="{{ $path | safeURL }}" alt="{{ .Text }}" {{ with .Title}} title="{{ . }}"{{ end }} />