summaryrefslogtreecommitdiffstats
path: root/docs/content/en/functions
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2020-01-05 11:14:51 +0100
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2020-01-05 11:14:51 +0100
commit469351d5b6a1521069c8d82539476714df16a094 (patch)
tree1a1ea21cac90f37742de3af5d5c954bfd66cadd3 /docs/content/en/functions
parent5ee1f0876f3ec8b79d6305298185dc821ead2d28 (diff)
parent26f1458a2df6b55eee3a5de46f5fec23a43a7c7d (diff)
Diffstat (limited to 'docs/content/en/functions')
-rw-r--r--docs/content/en/functions/RenderString.md4
-rw-r--r--docs/content/en/functions/ref.md8
-rw-r--r--docs/content/en/functions/relref.md8
-rw-r--r--docs/content/en/functions/safeURL.md2
4 files changed, 18 insertions, 4 deletions
diff --git a/docs/content/en/functions/RenderString.md b/docs/content/en/functions/RenderString.md
index 61f5d6417..e62f0cae0 100644
--- a/docs/content/en/functions/RenderString.md
+++ b/docs/content/en/functions/RenderString.md
@@ -15,6 +15,8 @@ signature: [".RenderString MARKUP"]
`.RenderString` is a method on `Page` that renders some markup to HTML using the content renderer defined for that page (if not set in the options).
+*Note* that this method does not parse and render shortcodes.
+
The method takes an optional map argument with these options:
display ("inline")
@@ -34,4 +36,4 @@ Some examples:
```
-**Note** that this method is more powerful than the similar [markdownify](functions/markdownify/) function as it also supports [Render Hooks](/getting-started/configuration-markup/#markdown-render-hooks) and it has options to render other markup formats. \ No newline at end of file
+**Note** that this method is more powerful than the similar [markdownify](/functions/markdownify/) function as it also supports [Render Hooks](/getting-started/configuration-markup/#markdown-render-hooks) and it has options to render other markup formats.
diff --git a/docs/content/en/functions/ref.md b/docs/content/en/functions/ref.md
index d63c0a89d..feac06c97 100644
--- a/docs/content/en/functions/ref.md
+++ b/docs/content/en/functions/ref.md
@@ -5,7 +5,7 @@ description: Looks up a content page by logical name.
godocref:
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-02-01
+lastmod: 2019-12-28
categories: [functions]
menu:
docs:
@@ -29,6 +29,12 @@ aliases: []
`ref` looks up Hugo "Regular Pages" only. It can't be used for the homepage, section pages, etc.
{{% /note %}}
+It is also possible to pass additional arguments to link to another language or an alternative output format. Therefore, pass a map of arguments instead of just the path.
+
+```
+{{ ref . (dict "path" "about.md" "lang" "ja" "outputFormat" "rss") }}
+```
+
These functions are used in two of Hugo's built-in shortcodes. You can see basic usage examples of both `ref` and `relref` in the [shortcode documentation](/content-management/shortcodes/#ref-and-relref).
For an extensive explanation of how to leverage `ref` and `relref` for content management, see [Cross References](/content-management/cross-references/).
diff --git a/docs/content/en/functions/relref.md b/docs/content/en/functions/relref.md
index ea992af2f..fe5699053 100644
--- a/docs/content/en/functions/relref.md
+++ b/docs/content/en/functions/relref.md
@@ -5,7 +5,7 @@ description: Looks up a content page by relative path.
godocref:
date: 2017-02-01
publishdate: 2017-02-01
-lastmod: 2017-02-01
+lastmod: 2019-12-28
categories: [functions]
menu:
docs:
@@ -29,6 +29,12 @@ aliases: []
`relref` looks up Hugo "Regular Pages" only. It can't be used for the homepage, section pages, etc.
{{% /note %}}
+It is also possible to pass additional arguments to link to another language or an alternative output format. Therefore, pass a map of arguments instead of just the path.
+
+```
+{{ relref . (dict "path" "about.md" "lang" "ja" "outputFormat" "rss") }}
+```
+
These functions are used in two of Hugo's built-in shortcodes. You can see basic usage examples of both `ref` and `relref` in the [shortcode documentation](/content-management/shortcodes/#ref-and-relref).
For an extensive explanation of how to leverage `ref` and `relref` for content management, see [Cross References](/content-management/cross-references/).
diff --git a/docs/content/en/functions/safeURL.md b/docs/content/en/functions/safeURL.md
index cb9979cd3..2e0733142 100644
--- a/docs/content/en/functions/safeURL.md
+++ b/docs/content/en/functions/safeURL.md
@@ -50,7 +50,7 @@ This partial would produce the following HTML output:
</ul>
{{< /output >}}
-The odd output can be remedied by adding ` | safeURL` to our `.Title` page variable:
+The odd output can be remedied by adding ` | safeURL` to our `.URL` page variable:
{{< code file="layouts/partials/correct-url-sidebar-menu.html" copy="false" >}}
<!-- This unordered list may be part of a sidebar menu -->