figbert.com-website

[ACTIVE] the website and home of figbert on the clearnet
git clone git://git.figbert.com/figbert.com-website.git
Log | Files | Refs | README | LICENSE

commit e0596fcf154037c25fd2614b89a506d6a402e7a8
parent e2493fb85e114b69ec8088902956a5e32ca866da
Author: FIGBERT <figbert@figbert.com>
Date:   Tue, 10 Nov 2020 17:38:49 -0800

Make media links in shortcodes absolute

Diffstat:
Mtemplates/shortcodes/audio.html | 2+-
Mtemplates/shortcodes/gif.html | 2+-
Mtemplates/shortcodes/image.html | 2+-
Mtemplates/shortcodes/video.html | 2+-
4 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/templates/shortcodes/audio.html b/templates/shortcodes/audio.html @@ -1,7 +1,7 @@ <audio controls> {% for source in sources %} {% set type = source | split(pat=".") | last %} - <source src="{{ source }}" type="{{ 'audio/' ~ type }}"> + <source src="{{ config.base_url | safe }}{{ page.path | safe }}{{ source | safe }}" type="{{ 'audio/' ~ type }}"> {% endfor %} Your browser doesn't support the audio tag and/or the audio formats in use here – sorry! </audio> diff --git a/templates/shortcodes/gif.html b/templates/shortcodes/gif.html @@ -1,7 +1,7 @@ <video autoplay loop muted playsinline> {% for source in sources %} {% set type = source | split(pat=".") | last %} - <source src="{{ source }}" type="{{ 'video/' ~ type }}"> + <source src="{{ config.base_url | safe }}{{ page.path | safe }}{{ source | safe }}" type="{{ 'video/' ~ type }}"> {% endfor %} Your browser doesn't support the video tag, which I use in place of .gifs, and/or the video formats in use here – sorry! </video> diff --git a/templates/shortcodes/image.html b/templates/shortcodes/image.html @@ -1,7 +1,7 @@ <picture> {% for source in sources %} {% set type = source | split(pat=".") | last %} - <source srcset="{{ source }}" type="{{ 'img/' ~ type }}"> + <source srcset="{{ config.base_url | safe}}{{ page.path | safe }}{{ source | safe }}" type="{{ 'img/' ~ type }}"> {% endfor %} <img src="{{ fallback_path }}" alt="{{ fallback_alt }}"/> </picture> diff --git a/templates/shortcodes/video.html b/templates/shortcodes/video.html @@ -1,7 +1,7 @@ <video controls> {% for source in sources %} {% set type = source | split(pat=".") | last %} - <source src="{{ source }}" type="{{ 'video/' ~ type }}"> + <source src="{{ config.base_url | safe }}{{ page.path | safe }}{{ source | safe }}" type="{{ 'video/' ~ type }}"> {% endfor %} Your browser doesn't support the video tag and/or the video formats in use here – sorry! </video>