From c2d72e09747a2a4abe9602e1ba49a1b4649c9d3c Mon Sep 17 00:00:00 2001 From: Jieiku Date: Fri, 14 Aug 2026 15:10:15 -0700 Subject: Update for Zola 0.23.3 --- templates/archive.html | 29 +++++++++++++---------------- 1 file changed, 13 insertions(+), 16 deletions(-) (limited to 'templates/archive.html') diff --git a/templates/archive.html b/templates/archive.html index aac705a..8bc0f27 100644 --- a/templates/archive.html +++ b/templates/archive.html @@ -7,24 +7,21 @@ This Template can also be used as the rendering template for Sections, eg: examp {%- set uglyurls = config.extra.uglyurls | default(value=false) -%} {%- if config.extra.search_library %}{%- if config.extra.search_library == "offline" %}{% set uglyurls = true %}{% endif %}{% endif %} -{%- block seo %} - {{- super() }} - {%- set title = "Archive" %} - - {%- if config.title %} - {%- set title_addition = title_separator ~ config.title %} - {%- else %} - {%- set title_addition = "" %} - {%- endif %} - - {%- set description = config.description %} - - {{- macros_seo::seo(config=config, title=title, title_addition=title_addition, description=description, is_home=true) }} -{%- endblock seo %} +{%- block seo -%} + {{- super() -}} + {%- set title = "Archive" -%} + {%- if config.title -%} + {%- set title_addition = title_separator ~ config.title -%} + {%- else -%} + {%- set title_addition = "" -%} + {%- endif -%} + {%- set description = config.description -%} + {{}} +{%- endblock seo -%} {%- block content %} {#- The following line is checking if the template is being used for the archive page or a section #} - {%- if current_path is matching("^(/[[:alpha:]][[:alpha:]])?/archive/$") %} + {%- if current_path is matching(pat="^(/[[:alpha:]][[:alpha:]])?/archive/$") %} {%- if section.extra.sec %} {%- set sec = section.extra.sec ~ "/" %} {%- else %} @@ -36,7 +33,7 @@ This Template can also be used as the rendering template for Sections, eg: examp {%- set langpath = "/" ~ lang ~ "/" %} {%- endif %} - {%- set sec = current_path | trim_start_matches(pat=langpath) | split(pat="/page/") | slice(end=1) | join(sep="") | trim_end_matches(pat="/") %} + {%- set sec = current_path | trim_start(pat=langpath) | split(pat="/page/") | first | trim_end(pat="/") %} {%- set sec = sec ~ "/" %} {%- endif %} -- cgit v1.3.1