{% if include.otherpost == true %} {% assign url = "/media/" | append: include.file %} {% else %} {% capture url %}/media/{{ page.path | remove: "_posts/" | remove: ".md" | append: "/" | append: include.file }}{% endcapture %} {% endif %} {% if include.caption %}
{% if include.alt %}{{ include.alt }}{% else %}Image{% endif %}
{{ include.caption }}
{% else %}
{% if include.alt %}{{ include.alt }}{% else %}Image{% endif %}
{% endif %}