diff --git a/files/templates/default.html b/files/templates/default.html index 48d0c85f6..add1c26c2 100644 --- a/files/templates/default.html +++ b/files/templates/default.html @@ -15,16 +15,11 @@ {% set class = 'site-banner-hole' %} {% elif SITE_NAME == "rDrama" %} {% set href = "https://secure.transequality.org/site/Donation2?df_id=1480" %} + {% set expand = false %} {% elif SITE_NAME == 'PCM' %}{# special case: christmas #} {% set src = "/i/PCM/banners_xmas22/" ~ listdir('files/assets/images/PCM/banners_xmas22')|random() %} - {% elif SITE_NAME == "WPD" %} - {% if sub %} - {% set href = "/h/" ~ sub %} - {% else %} - {% set href = "/" %} - {% endif %} {% endif %} - {{macros.banner(src, href, alt, class)}} + {{macros.banner(src, href, alt, expand, class)}} {% endif %} {% endif %} {% endblock %} diff --git a/files/templates/util/macros.html b/files/templates/util/macros.html index a6937337b..2e4c04f87 100644 --- a/files/templates/util/macros.html +++ b/files/templates/util/macros.html @@ -4,8 +4,7 @@ {%- endif -%} {%- endmacro -%} -{%- macro banner(src, href, alt, class) %} - {% set expand = not href %} +{%- macro banner(src, href, alt, expand, class) %} {{alt|default('site banner')}}