forked from rDrama/rDrama
parent
b7bbc2cc1e
commit
47d597a716
|
@ -15,11 +15,16 @@
|
||||||
{% set class = 'site-banner-hole' %}
|
{% set class = 'site-banner-hole' %}
|
||||||
{% elif SITE_NAME == "rDrama" %}
|
{% elif SITE_NAME == "rDrama" %}
|
||||||
{% set href = "https://secure.transequality.org/site/Donation2?df_id=1480" %}
|
{% set href = "https://secure.transequality.org/site/Donation2?df_id=1480" %}
|
||||||
{% set expand = false %}
|
|
||||||
{% elif SITE_NAME == 'PCM' %}{# special case: christmas #}
|
{% elif SITE_NAME == 'PCM' %}{# special case: christmas #}
|
||||||
{% set src = "/i/PCM/banners_xmas22/" ~ listdir('files/assets/images/PCM/banners_xmas22')|random() %}
|
{% 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 %}
|
{% endif %}
|
||||||
{{macros.banner(src, href, alt, expand, class)}}
|
{{macros.banner(src, href, alt, class)}}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
|
@ -4,7 +4,8 @@
|
||||||
{%- endif -%}
|
{%- endif -%}
|
||||||
{%- endmacro -%}
|
{%- endmacro -%}
|
||||||
|
|
||||||
{%- macro banner(src, href, alt, expand, class) %}
|
{%- macro banner(src, href, alt, class) %}
|
||||||
|
{% set expand = not href %}
|
||||||
<a href="{{href|default(src)}}" rel="nofollow noopener">
|
<a href="{{href|default(src)}}" rel="nofollow noopener">
|
||||||
<img onclick="{{expand|default('expandDesktopImage()')}}" class="{{class|default('site-banner')}}" alt="{{alt|default('site banner')}}" src="{{src|default(live_banner())}}">
|
<img onclick="{{expand|default('expandDesktopImage()')}}" class="{{class|default('site-banner')}}" alt="{{alt|default('site banner')}}" src="{{src|default(live_banner())}}">
|
||||||
</a>
|
</a>
|
||||||
|
|
Loading…
Reference in New Issue