aboutsummaryrefslogtreecommitdiff
path: root/layouts/book/single.html
diff options
context:
space:
mode:
Diffstat (limited to 'layouts/book/single.html')
-rw-r--r--layouts/book/single.html15
1 files changed, 14 insertions, 1 deletions
diff --git a/layouts/book/single.html b/layouts/book/single.html
index 3ffb236..0bbd265 100644
--- a/layouts/book/single.html
+++ b/layouts/book/single.html
@@ -4,7 +4,20 @@
4 <h4>{{ .Params.author }}</h4> 4 <h4>{{ .Params.author }}</h4>
5 <h6>{{ .Date | time.Format ":date_full" }}</h6> 5 <h6>{{ .Date | time.Format ":date_full" }}</h6>
6 {{ if isset .Params "image" }} 6 {{ if isset .Params "image" }}
7 <img src="{{ .Params.image }}" alt="Book cover of the book {{ .Title }}" /> 7 {{ with resources.GetRemote .Params.image }}
8 {{ with .Err }}
9 {{ errorf "%s" . }}
10 {{ else }}
11 <img
12 src="{{ .RelPermalink }}"
13 width="{{ .Width }}"
14 height="{{ .Height }}"
15 alt="Book cover of the book {{ .Title }}"
16 />
17 {{ end }}
18 {{ else }}
19 {{ errorf "unable to get remote resource %q" .Params.image }}
20 {{ end }}
8 {{ end }} 21 {{ end }}
9 {{ if isset .Params "amazon" }} 22 {{ if isset .Params "amazon" }}
10 <p> 23 <p>