Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mattstratton/castanet.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatt Stratton <matt.stratton@gmail.com>2017-05-02 14:16:00 +0300
committerMatt Stratton <matt.stratton@gmail.com>2017-05-02 14:16:00 +0300
commitd3f518954a0424ce2a789ffc83517883ef2e4ce0 (patch)
treee2448a8c7005260ea075766c5c52d9f93cb47764
parentef2444fd82aa5ee04cbe91874607f6bf2bb445d8 (diff)
Construct pager properly
-rw-r--r--layouts/episode/single.html8
-rw-r--r--layouts/partials/row.html2
2 files changed, 5 insertions, 5 deletions
diff --git a/layouts/episode/single.html b/layouts/episode/single.html
index 68cf8f0..f05bccf 100644
--- a/layouts/episode/single.html
+++ b/layouts/episode/single.html
@@ -8,7 +8,7 @@
<div class="row">
<div class="col-md-3">
- <img src="{{ .Params.episode_image }}" class="img-fluid episode_image"/>
+ <img src="{{ .Params.episode_image | absURL }}" class="img-fluid episode_image"/>
</div>
<div class="col-md-8">
{{ .Description | markdownify }}
@@ -41,16 +41,16 @@
<div class="col-md-3">
{{ if and (isset .Params "thumbnail") (ne .Params.thumbnail "") }}
{{ if (eq (slicestr .Params.thumbnail 0 4) "http") }}
- <img alt="{{ .Title }}" src="{{ .Params.thumbnail}}" class="img-responsive" width="250px">
+ <img alt="{{ .Title }}" src="{{ .Params.thumbnail }}" class="img-responsive" width="250px">
{{ else }}
- <img alt="{{ .Title }}" src="{{ $.Site.BaseURL }}{{ .Params.thumbnail}}" class="img-responsive" width="250px">
+ <img alt="{{ .Title }}" src="{{ .Params.thumbnail | absURL}}" class="img-responsive" width="250px">
{{ end }}
{{ else }}
<img alt="{{ .Title }}" src="{{ $.Site.BaseURL }}/img/guest/default-guest.png" class="img-responsive" width="250px"/>
{{ end }}
</div>
<div class="col-md-8">
- <h2><a href = "/guest/{{.File.BaseFileName}}">{{ .Title }}</a></h2>
+ <h2><a href = "{{(printf "guest/%s" .File.BaseFileName) | absURL }}">{{ .Title }}</a></h2>
{{ .Content }}
{{ if .Params.Website }}
<a href="{{ .Params.Website }}">
diff --git a/layouts/partials/row.html b/layouts/partials/row.html
index ef7c8e6..b83597a 100644
--- a/layouts/partials/row.html
+++ b/layouts/partials/row.html
@@ -82,7 +82,7 @@
<a href="{{ if $paginator.HasPrev }}{{ $paginator.Prev.URL }}{{ end }}" aria-label="Previous" class="page-link"><span aria-hidden="true">&laquo;</span></a>
</li>
{{ range $paginator.Pagers }}
- <li class="{{ if eq . $paginator }}active {{ end }}page-item"><a href="{{ .URL | absURL }}" class="page-link hidden-md-down">{{ .PageNumber }}</a></li>
+ <li class="{{ if eq . $paginator }}active {{ end }}page-item"><a href="{{ $.Site.BaseURL}}{{ .URL }}" class="page-link hidden-md-down">{{ .PageNumber }}</a></li>
{{ end }}
<li class="{{ if not $paginator.HasNext }}disabled {{ end }}page-item">
<a href="{{ if $paginator.HasNext }}{{ $paginator.Next.URL }}{{ end }}" aria-label="Next" class="page-link"><span aria-hidden="true">&raquo;</span></a>