{% if not section.pageblock_set.all.count %}

[EMPTY SECTION]

{% else %} {% for block in blocks %} {% if block.label %}

{{block.label}}

{% endif %} {% if block.unrenderable %}

Unrenderable Block: {{block.content_object.display_name}}

{% else %} {{block.epub_content|safe}} {% endif %} {% endfor %} {% endif %}