Generate Edit button only if page.edit_url

This commit is contained in:
Roberto Jimenez Sanchez 2017-11-08 00:19:13 +01:00 committed by Martin Donath
parent 0f9a76f452
commit e472e2d0b1
2 changed files with 2 additions and 2 deletions

View File

@ -129,7 +129,7 @@
<div class="md-content"> <div class="md-content">
<article class="md-content__inner md-typeset"> <article class="md-content__inner md-typeset">
{% block content %} {% block content %}
{% if config.edit_uri %} {% if page.edit_url %}
<a href="{{ page.edit_url }}" title="{{ lang.t('edit.link.title') }}" class="md-icon md-content__icon">&#xE3C9;</a> <a href="{{ page.edit_url }}" title="{{ lang.t('edit.link.title') }}" class="md-icon md-content__icon">&#xE3C9;</a>
{% endif %} {% endif %}
{% if not "\x3ch1" in page.content %} {% if not "\x3ch1" in page.content %}

View File

@ -242,7 +242,7 @@
{% block content %} {% block content %}
<!-- Edit button, if URL was defined --> <!-- Edit button, if URL was defined -->
{% if config.edit_uri %} {% if page.edit_url %}
<a href="{{ page.edit_url }}" <a href="{{ page.edit_url }}"
title="{{ lang.t('edit.link.title') }}" title="{{ lang.t('edit.link.title') }}"
class="md-icon md-content__icon">&#xE3C9;<!-- edit --></a> class="md-icon md-content__icon">&#xE3C9;<!-- edit --></a>