diff --git a/layouts/partials/components/breadcrumb.html b/layouts/partials/components/breadcrumb.html index 375c863..7bcd3cd 100644 --- a/layouts/partials/components/breadcrumb.html +++ b/layouts/partials/components/breadcrumb.html @@ -1,9 +1,9 @@ {{ $context := .Context }} {{ $class := .Class }} {{ $base := site.BaseURL }} -{{ $url := replace $context.Permalink ( printf "%s" $base) "" }} +{{ $pageLink := replace $context.Permalink $base "" }} {{ $lang := $context.Lang }} -{{ $.Scratch.Add "path" $base }} +{{ $context.Scratch.Set "path" "/" }} diff --git a/layouts/partials/components/language-switcher.html b/layouts/partials/components/language-switcher.html index 06d310d..330baed 100644 --- a/layouts/partials/components/language-switcher.html +++ b/layouts/partials/components/language-switcher.html @@ -4,7 +4,7 @@ {{ $pageLang := $context.Lang }} {{ $base:= urls.Parse site.BaseURL }} {{ $siteLanguages := site.Home.AllTranslations }} -{{ $pageLink := replace (replace (replace $context.RelPermalink $pageLang "") "//" "/") $base.Path "" }} +{{ $pageLink := replace (replace (replace $context.RelPermalink $pageLang "") "//" "/") $base.Path "/" }} {{ if $context.IsTranslated }}