Links zoveel mogelijk relatief ipv absoluut

This commit is contained in:
Michael Boelen 2023-06-01 20:16:32 +02:00
parent 3010fb699a
commit bc191b7905
5 changed files with 7 additions and 7 deletions

View file

@ -22,7 +22,7 @@
<ul> <ul>
{{ range .Pages }} {{ range .Pages }}
<li> <li>
<a class="link" href="{{ .Permalink }}" title="{{ .Title }}">{{ .Title | default .Site.Params.textNoTitle }}</a> <a class="link" href="{{ .RelPermalink }}" title="{{ .Title }}">{{ .Title | default .Site.Params.textNoTitle }}</a>
</li> </li>
{{ end }} {{ end }}
</ul> </ul>
@ -37,7 +37,7 @@
{{ $taxonomy := "tags" }} {{ with .Param $taxonomy }} {{ $taxonomy := "tags" }} {{ with .Param $taxonomy }}
<ul> <ul>
{{ range $index, $tag := . }} {{ with $.Site.GetPage (printf "/%s/%s" $taxonomy $tag) -}} {{ range $index, $tag := . }} {{ with $.Site.GetPage (printf "/%s/%s" $taxonomy $tag) -}}
<li><a href="{{ .Permalink }}">{{ $tag | urlize }}</a></li> <li><a href="{{ .RelPermalink }}">{{ $tag | urlize }}</a></li>
{{- end -}} {{- end -}} {{- end -}} {{- end -}}
</ul> </ul>
{{ end }} {{ end }}

View file

@ -3,7 +3,7 @@
<ul class="list"> <ul class="list">
{{ range .Pages }} {{ range .Pages }}
<li> <li>
<a class="link" href="{{ .Permalink }}" title="{{ .Title }}">{{ .Title }}</a> <a class="link" href="{{ .RelPermalink }}" title="{{ .Title }}">{{ .Title }}</a>
<hr class="hr-list"> <hr class="hr-list">
<time class="g time" datetime="{{ dateFormat "2006-01-02" .Date }}">{{ dateFormat "02-01-2006" .Date }}</time> <time class="g time" datetime="{{ dateFormat "2006-01-02" .Date }}">{{ dateFormat "02-01-2006" .Date }}</time>
</li> </li>

View file

@ -8,7 +8,7 @@
<ul class="list"> <ul class="list">
{{ range (first 5 (where .Site.RegularPages "Section" "nieuws").ByDate.Reverse) }} {{ range (first 5 (where .Site.RegularPages "Section" "nieuws").ByDate.Reverse) }}
<li> <li>
<a class="link" href="{{ .Permalink }}" title="{{ .Title }}">{{ .Title }}</a> <a class="link" href="{{ .RelPermalink }}" title="{{ .Title }}">{{ .Title }}</a>
<hr class="hr-list"> <hr class="hr-list">
<time class="g time" datetime="{{ dateFormat "2006-01-02" .Date }}">{{ dateFormat "02-01-2006" .Date }}</time> <time class="g time" datetime="{{ dateFormat "2006-01-02" .Date }}">{{ dateFormat "02-01-2006" .Date }}</time>
</li> </li>

View file

@ -11,7 +11,7 @@
{{ end }} {{ end }}
{{ end }} {{ end }}
<li class="active"> <li class="active">
<a aria-current="page" href="{{ .Permalink }}">{{ .LinkTitle }}</a> <a aria-current="page" href="{{ .RelPermalink }}">{{ .LinkTitle }}</a>
</li> </li>
</ol> </ol>
</nav> </nav>

View file

@ -34,8 +34,8 @@
<h2>Nuttige links</h2> <h2>Nuttige links</h2>
<nav aria-label="Footer links"> <nav aria-label="Footer links">
<ul> <ul>
<li><a href="{{ absURL "contact/" }}">Contact</a></li> <li><a href="{{ relURL "contact/" }}">Contact</a></li>
<li><a href="{{ absURL "privacy/" }}">Privacy</a></li> <li><a href="{{ relURL "privacy/" }}">Privacy</a></li>
</ul> </ul>
</nav> </nav>
</div> </div>