mirror of
https://github.com/zaaarf/friendenstein.git
synced 2024-11-22 15:34:50 +01:00
feat: external link redirect
This commit is contained in:
parent
e8addb1d70
commit
a7b25ca5cc
2 changed files with 15 additions and 6 deletions
|
@ -17,6 +17,10 @@
|
||||||
{{ marginals::navbar(current_lang=current_lang) }}
|
{{ marginals::navbar(current_lang=current_lang) }}
|
||||||
</header>
|
</header>
|
||||||
<main>
|
<main>
|
||||||
|
{%- if page.extra.redirect -%}
|
||||||
|
<meta http-equiv="Refresh" content="0; url='{{ page.extra.redirect }}'" />
|
||||||
|
{%- endif -%}
|
||||||
|
|
||||||
{% block pre_content %}
|
{% block pre_content %}
|
||||||
{% endblock pre_content %}
|
{% endblock pre_content %}
|
||||||
<article>
|
<article>
|
||||||
|
|
|
@ -5,11 +5,11 @@
|
||||||
|
|
||||||
{{ section.content | safe }}
|
{{ section.content | safe }}
|
||||||
|
|
||||||
{% if paginator %}
|
{%- if paginator -%}
|
||||||
{% set pages = paginator.pages %}
|
{%- set pages = paginator.pages -%}
|
||||||
{% else %}
|
{%- else -%}
|
||||||
{% set pages = section.pages %}
|
{% set pages = section.pages -%}
|
||||||
{% endif %}
|
{%- endif -%}
|
||||||
|
|
||||||
<ul class="title-list">
|
<ul class="title-list">
|
||||||
{%- for page in pages -%}
|
{%- for page in pages -%}
|
||||||
|
@ -22,7 +22,12 @@
|
||||||
{%- else -%}
|
{%- else -%}
|
||||||
{% set datefmt = " @ %Y-%m-%dT%H:%M:%S%Z" %}
|
{% set datefmt = " @ %Y-%m-%dT%H:%M:%S%Z" %}
|
||||||
{%- endif -%}
|
{%- endif -%}
|
||||||
<li><a href="{{ page.permalink | safe }}">{{ page.title }}
|
{%- if page.extra.redirect -%}
|
||||||
|
{%- set page_link = page.extra.redirect -%}
|
||||||
|
{%- else -%}
|
||||||
|
{%- set page_link = page.permalink -%}
|
||||||
|
{%- endif -%}
|
||||||
|
<li><a href="{{ page_link | safe }}">{{ page.title }}
|
||||||
{%- if section.extra.show_subtitle and section.extra.show_subtitle == true and page.extra.subtitle -%}
|
{%- if section.extra.show_subtitle and section.extra.show_subtitle == true and page.extra.subtitle -%}
|
||||||
<span class="content-subtitle"> - {{ page.extra.subtitle }}</span>
|
<span class="content-subtitle"> - {{ page.extra.subtitle }}</span>
|
||||||
{%- endif -%}
|
{%- endif -%}
|
||||||
|
|
Loading…
Reference in a new issue