mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-21 21:35:28 +02:00
Merge commit '5be51ac3db225d5df501ed1fa1499c41d97dbf65'
This commit is contained in:
@@ -3,14 +3,10 @@ title: BaseURL
|
||||
description: Returns the base URL as defined in the site configuration.
|
||||
categories: []
|
||||
keywords: []
|
||||
action:
|
||||
related:
|
||||
- functions/urls/AbsURL
|
||||
- functions/urls/AbsLangURL
|
||||
- functions/urls/RelURL
|
||||
- functions/urls/RelLangURL
|
||||
returnType: string
|
||||
signatures: [SITE.BaseURL]
|
||||
params:
|
||||
functions_and_methods:
|
||||
returnType: string
|
||||
signatures: [SITE.BaseURL]
|
||||
---
|
||||
|
||||
Site configuration:
|
||||
@@ -25,13 +21,12 @@ Template:
|
||||
{{ .Site.BaseURL }} → https://example.org/docs/
|
||||
```
|
||||
|
||||
{{% note %}}
|
||||
There is almost never a good reason to use this method in your templates. Its usage tends to be fragile due to misconfiguration.
|
||||
> [!note]
|
||||
> There is almost never a good reason to use this method in your templates. Its usage tends to be fragile due to misconfiguration.
|
||||
>
|
||||
> Use the [`absURL`], [`absLangURL`], [`relURL`], or [`relLangURL`] functions instead.
|
||||
|
||||
Use the [`absURL`], [`absLangURL`], [`relURL`], or [`relLangURL`] functions instead.
|
||||
|
||||
[`absURL`]: /functions/urls/absURL/
|
||||
[`absLangURL`]: /functions/urls/absLangURL/
|
||||
[`relURL`]: /functions/urls/relURL/
|
||||
[`absURL`]: /functions/urls/absURL/
|
||||
[`relLangURL`]: /functions/urls/relLangURL/
|
||||
{{% /note %}}
|
||||
[`relURL`]: /functions/urls/relURL/
|
||||
|
Reference in New Issue
Block a user