Do not only use ugly URLs; have support for relative or ugly

This commit is contained in:
Tony Blyler 2016-11-03 21:14:36 -04:00
parent ddcf6a28d0
commit b781218f4e
4 changed files with 16 additions and 17 deletions
layouts/partials

View file

@ -1,10 +1,10 @@
<div class="links">
<a href="{{ .Site.BaseURL }}">Home</a>
<a href="/">Home</a>
{{ range first 1 (where .Site.Pages "Type" "post") }}
<a href="{{ .Site.BaseURL }}/post/">Archive</a>
<a href="/post/">Archive</a>
{{ end }}
{{ range where .Site.Pages "Type" "!=" "post" }}
<a href="{{ .Permalink }}">{{ .Title }}</a>
<a href="{{ .RelPermalink }}">{{ .Title }}</a>
{{ end }}
<a href="#top">Top</a>
</div>