Holger Frey
7 years ago
5 changed files with 54 additions and 15 deletions
@ -1,8 +0,0 @@ |
|||||||
{% extends "layout.jinja2" %} |
|
||||||
|
|
||||||
{% block content %} |
|
||||||
<div class="content"> |
|
||||||
<h1><span class="font-semi-bold">Pyramid</span> <span class="smaller">Alchemy scaffold</span></h1> |
|
||||||
<p class="lead"><span class="font-semi-bold">404</span> Page Not Found</p> |
|
||||||
</div> |
|
||||||
{% endblock content %} |
|
@ -0,0 +1,18 @@ |
|||||||
|
{% extends "ordr2:templates/layout.jinja2" %} |
||||||
|
|
||||||
|
{% block subtitle %} Access Denied {% endblock subtitle %} |
||||||
|
|
||||||
|
{% block content %} |
||||||
|
<div class="container"> |
||||||
|
<div class="row"> |
||||||
|
|
||||||
|
<div class="span12"> |
||||||
|
<hgroup id="access-denied"> |
||||||
|
<h1>Access Denied!!!</h1> |
||||||
|
<p class="info">You do not have the permission to access this page.</p> |
||||||
|
</hgroup> |
||||||
|
</div> |
||||||
|
|
||||||
|
</div> |
||||||
|
</div> |
||||||
|
{% endblock content %} |
@ -0,0 +1,18 @@ |
|||||||
|
{% extends "ordr2:templates/layout.jinja2" %} |
||||||
|
|
||||||
|
{% block subtitle %} Not Found {% endblock subtitle %} |
||||||
|
|
||||||
|
{% block content %} |
||||||
|
<div class="container"> |
||||||
|
<div class="row"> |
||||||
|
|
||||||
|
<div class="span12"> |
||||||
|
<hgroup id="access-denied"> |
||||||
|
<h1>These are not the droids<br>you are looking for</h1> |
||||||
|
<p class="info">Whatever you wanted to see was not found on this server.</p> |
||||||
|
</hgroup> |
||||||
|
</div> |
||||||
|
|
||||||
|
</div> |
||||||
|
</div> |
||||||
|
{% endblock content %} |
@ -0,0 +1,18 @@ |
|||||||
|
from pyramid.view import ( |
||||||
|
notfound_view_config, |
||||||
|
forbidden_view_config |
||||||
|
) |
||||||
|
|
||||||
|
|
||||||
|
@notfound_view_config(renderer='ordr2:templates/errors/not_found.jinja2') |
||||||
|
def notfound_view(context, request): |
||||||
|
context.nav_highlight = 'errors' |
||||||
|
request.response.status = 404 |
||||||
|
return {} |
||||||
|
|
||||||
|
|
||||||
|
@forbidden_view_config(renderer='ordr2:templates/errors/forbidden.jinja2') |
||||||
|
def forbidden_view(context, request): |
||||||
|
request.response.status = 403 |
||||||
|
context.nav_highlight = 'errors' |
||||||
|
return {} |
Reference in new issue