Events

{% set no_events = namespace(event=false) %} {% if site.custom_fields['name_of_event_1'] or site.custom_fields['name_of_event_2'] or site.custom_fields['name_of_event_3'] or site.custom_fields['name_of_event_4'] or site.custom_fields['name_of_event_5'] or site.custom_fields['name_of_event_6'] or site.custom_fields['name_of_event_7'] or site.custom_fields['name_of_event_8'] or site.custom_fields['name_of_event_9'] or site.custom_fields['name_of_event_10'] %}

Upcoming Events

{% for i in range(1, 10) %} {% set image_value_key = 'photo_of_event_%s' % i %} {% set name_value_key = 'name_of_event_%s' % i %} {% set location_value_key = 'location_of_event_%s' % i %} {% set enddate_value_key = 'end_date_of_event_%s' % i %} {% set startdate_value_key = 'start_date_of_event_%s' % i %} {% set time_value_key = 'time_of_event_%s' % i %} {% set content_value_key = 'description_of_event_%s' % i %} {% if site.custom_fields[name_value_key] %} {% if site.custom_fields[enddate_value_key]|to_date(format='%m/%d/%Y')|is_today or site.custom_fields[enddate_value_key]|to_date(format='%m/%d/%Y')|is_future %}

{{ site.custom_fields[name_value_key] }}

Start date: {{ site.custom_fields[startdate_value_key] }}

End date: {{ site.custom_fields[enddate_value_key] }}

Time: {{ site.custom_fields[time_value_key] }}

Location: {{ site.custom_fields[location_value_key] }}

{{ site.custom_fields[name_value_key] }}

{{ site.custom_fields[content_value_key] }}

{% set no_events.event = True %} {% endif %} {% endif %} {% endfor %} {% endif %} {% if no_events.event == False %}

There are no events.

{% endif %}