{% extends "base.html" %} {% load wagtailcore_tags wagtailimages_tags i18n el_pagination_tags %} {% block content %} {% if search_results %} {% paginate 10 results as paginated_results %} {% for page in paginated_results %} {% with parent_section=page.get_parent_section ancestor=page.get_parent_section.get_ancestors.last %} {% if ancestor.sectionpage.image %}
{{ancestor.title}}
{% else %}
{{parent_section.title}}
{% endif %} {% if page.title_highlight %}

{{page.title_highlight|safe}}

{% else %}

{{page.title}}

{% endif %} {% if page.subtitle_highlight or page.body_highlight %} {% if page.subtitle_highlight %}

{{page.subtitle_highlight|safe}}

{% elif page.body_highlight %}

{{page.body_highlight|safe}}

{% endif %} {% else %}

{{page.subtitle}}

{% endif %}
{% endwith %} {% endfor %} {% get_pages %} {% if pages.next %} Load More {% endif %} {% else %} {% endif %} {% endblock %} {% block search %} {% if search_results %} {% include "search/search_block.html" %} {% endif %} {% endblock %}