diff options
author | digitalcraftsman <digitalcraftsman@users.noreply.github.com> | 2016-02-01 18:52:47 +0300 |
---|---|---|
committer | digitalcraftsman <digitalcraftsman@users.noreply.github.com> | 2016-02-01 18:54:27 +0300 |
commit | ec02b9908cef4f4e022d9bd207c64a3ca086b57a (patch) | |
tree | 5b4ffe76a505283a7fa0d0a0d33ae864aa250ad8 | |
parent | 243fbbf0f96c89f3ac5b5a0c061d18e4473934cf (diff) |
Fixed example and cross-reference in content/variables.md
Fixed a path in a Page Params example to reflect real directory
structure, removed extra quotes from sample code, and fixed link to
Archetypes which read "cross-references" before.
See #1805
-rw-r--r-- | docs/content/templates/variables.md | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/docs/content/templates/variables.md b/docs/content/templates/variables.md index 2f0a2279b..ed227e316 100644 --- a/docs/content/templates/variables.md +++ b/docs/content/templates/variables.md @@ -75,9 +75,9 @@ This is particularly useful for the introduction of user defined fields in conte recommendedby: "my Mother" --- -Which would then be accessible to a template at `/theme/yourtheme/review/single.html`, for example, through `.Params.affiliatelink` and `.Params.recommendedby`, respectively. Two common situations where these could be introduced are as a value of a certain attribute (like `href=""` below) or by itself if it will be displayed. Sample syntaxes include: +Which would then be accessible to a template at `/themes/yourtheme/layouts/review/single.html` through `.Params.affiliatelink` and `.Params.recommendedby`, respectively. Two common situations where these could be introduced are as a value of a certain attribute (like `href=""` below) or by itself to be displayed. Sample syntaxes include: - <h3><a href="{{ printf "%s" $.Params.affiliatelink }}">Buy this book</a></h3> + <h3><a href={{ printf "%s" $.Params.affiliatelink }}>Buy this book</a></h3> <p>It was recommended by {{ .Params.recommendedby }}.</p> which would render @@ -85,7 +85,7 @@ which would render <h3><a href="http://www.my-book-link.here">Buy this book</a></h3> <p>It was recommended by my Mother.</p> -**See also:** [cross-references]({{% ref "content/archetypes.md" %}}) for consistency of `Params` across pieces of content. +**See also:** [Archetypes]({{% ref "content/archetypes.md" %}}) for consistency of `Params` across pieces of content. ### Param method In Hugo you can declare params both for the site and the individual page. A common use case is to have a general value for the site and a more specific value for some of the pages (i.e. an image). |