Created
January 14, 2015 18:05
-
-
Save SalahAdDin/5a4ab352ea8a0162e625 to your computer and use it in GitHub Desktop.
Wagtail Template Errors
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% extends "error_base.html" %} | |
{% load i18n %} | |
{% block titletag %}{% trans 'Client Error' %}{% endblock %} | |
{% block body_class %}template-400{% endblock %} | |
{% block content %} | |
% trans "There's been an error. We have problems with customer requests, ie, of your computer, please check it." %} | |
{% endblock %} | |
{% block error %}<span>400</span>{% trans 'error'|capfirst %}{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% extends "error_base.html" %} | |
{% load i18n %} | |
{% block titletag %}{% trans 'forbidden'|capfirst %}{% endblock %} | |
{% block body_class %}template-403{% endblock %} | |
{% block content %} | |
{% trans "We're sorry, but the requested action is forbidden" %} | |
{% endblock %} | |
{% block error %}<span>403</span>{% trans 'error'|capfirst %}{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% extends "error_base.html" %} | |
{% load i18n %} | |
{% block titletag %}{% trans 'Page not found' %}{% endblock %} | |
{% block body_class %}template-404{% endblock %} | |
{% block content %} | |
{% trans "We're sorry, but the requested page could not be found." %} | |
{% endblock %} | |
{% block error %}<span>404</span>{% trans 'error'|capfirst %}{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% extends "error_base.html" %} | |
{% load i18n %} | |
{% block titletag %}{% trans 'Server Error' %}{% endblock %} | |
{% block body_class %}template-500{% endblock %} | |
{% block content %} | |
{% trans "There's been an error. It's been reported to the site administrators via e-mail and should be fixed shortly. Thanks for your patience." %} | |
{% endblock %} | |
{% block error %}<span>500</span>{% trans 'error'|capfirst %}{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% extends "wagtailadmin/admin_base.html" %} | |
{% load wagtailadmin_tags wagtailcore_tags %} | |
{% load i18n %} | |
{% block extra_css %} | |
{% compress css %} | |
<link rel="stylesheet" href="{{ STATIC_URL }}wagtailadmin/scss/layouts/home.scss" type="text/x-scss"/> | |
{% endcompress %} | |
{% endblock %} | |
{% block furniture %} | |
<div class="content-wrapper"> | |
<div class="content"> | |
<header class="merged nice-padding"> | |
<div class="row row-flush"> | |
{% if user.email %} | |
<div class="col9"> | |
<h1>{% block titletag %}{% endblock %}</h1> | |
<h2>{% block content %}{% endblock %}</h2> | |
</div> | |
</div> | |
</header> | |
{# Always show messages div so it can be appended to by JS #} | |
<section class="panel summary nice-padding"> | |
<ul class="stats"> | |
<li></li> | |
<li><a>{% block error %}{% endblock %}</a></li> | |
<li></li> | |
</ul> | |
</section> | |
<div class="panel nice-padding"> | |
<section> | |
<script type="text/javascript"> | |
if(window.location.href.toString().indexOf('popup') != -1){ | |
document.write('<a href="javascript:window.close()" class="btn btn-info btn-large">{% trans 'Close window' %}</a> '); | |
}else { | |
if (document.referrer != '') { | |
document.write('<a href="javascript:history.back()" class="btn btn-info btn-large">{% trans 'Go back' %}</a> '); | |
} | |
{% if request and user.is_authenticated and user.is_staff %} | |
document.write('<a href="{% url 'admin:index' %}" class="btn btn-large">Go to admin home</a> '); | |
{% endif %} | |
} | |
</script> | |
</section> | |
</div> | |
</div> | |
</div> | |
{% endblock %} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment