From 18e2c3115240bc49cf33de07bc6b6d148791b2d4 Mon Sep 17 00:00:00 2001 From: samaradel Date: Thu, 21 Jul 2022 21:04:05 +0200 Subject: [PATCH] test btns --- templates/shortcodes/button.html | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/templates/shortcodes/button.html b/templates/shortcodes/button.html index f6576a4dd..f25270f55 100644 --- a/templates/shortcodes/button.html +++ b/templates/shortcodes/button.html @@ -1,3 +1,5 @@ +{% set base = config.base_url %} + {% set path = body | split(pat="href=") | slice(start=1) | first | split(pat=">") | first | trim_start_matches(pat='"') | trim_end_matches(pat='"') %} @@ -7,8 +9,8 @@ {{ body | trim_start_matches(pat="

") | safe}} -{% elif path is starting_with('/') %} -{% set btn_path = 'www_threefold_io/' ~ path %} +{% elif base is containing("www_threefold_io") %} +{% set btn_path = base ~ path %}