From 1ed20244333066fd5ec7504e03a53ac8cc108385 Mon Sep 17 00:00:00 2001 From: Bo-Chun Louis Chen <louistw@uab.edu> Date: Thu, 24 May 2018 15:13:30 -0500 Subject: [PATCH] Added error templates --- app/templates/errors/403.html | 21 +++++++++++++++++++++ app/templates/errors/404.html | 21 +++++++++++++++++++++ app/templates/errors/500.html | 21 +++++++++++++++++++++ 3 files changed, 63 insertions(+) create mode 100644 app/templates/errors/403.html create mode 100644 app/templates/errors/404.html create mode 100644 app/templates/errors/500.html diff --git a/app/templates/errors/403.html b/app/templates/errors/403.html new file mode 100644 index 0000000..3e366d9 --- /dev/null +++ b/app/templates/errors/403.html @@ -0,0 +1,21 @@ +{% extends "base.html" %} +{% block title %}Forbidden{% endblock %} +{% block body %} +<div class="content-section"> + <div class="outer"> + <div class="middle"> + <div class="inner"> + <div style="text-align: center"> + <h1> 403 Error </h1> + <h3> You do not have sufficient permissions to access this page. </h3> + <hr class="intro-divider"> + <a href="{{ url_for('home.homepage') }}" class="btn btn-default btn-lg"> + <i class="fa fa-home"></i> + Home + </a> + </div> + </div> + </div> + </div> +</div> +{% endblock %} diff --git a/app/templates/errors/404.html b/app/templates/errors/404.html new file mode 100644 index 0000000..0c88fd2 --- /dev/null +++ b/app/templates/errors/404.html @@ -0,0 +1,21 @@ +{% extends "base.html" %} +{% block title %}Page Not Found{% endblock %} +{% block body %} +<div class="content-section"> + <div class="outer"> + <div class="middle"> + <div class="inner"> + <div style="text-align: center"> + <h1> 404 Error </h1> + <h3> The page you're looking for doesn't exist. </h3> + <hr class="intro-divider"> + <a href="{{ url_for('home.homepage') }}" class="btn btn-default btn-lg"> + <i class="fa fa-home"></i> + Home + </a> + </div> + </div> + </div> + </div> +</div> +{% endblock %} diff --git a/app/templates/errors/500.html b/app/templates/errors/500.html new file mode 100644 index 0000000..a6e9831 --- /dev/null +++ b/app/templates/errors/500.html @@ -0,0 +1,21 @@ +{% extends "base.html" %} +{% block title %}Internal Server Error{% endblock %} +{% block body %} +<div class="content-section"> + <div class="outer"> + <div class="middle"> + <div class="inner"> + <div style="text-align: center"> + <h1> 500 Error </h1> + <h3> The server encountered an internal error. That's all we know. </h3> + <hr class="intro-divider"> + <a href="{{ url_for('home.homepage') }}" class="btn btn-default btn-lg"> + <i class="fa fa-home"></i> + Home + </a> + </div> + </div> + </div> + </div> +</div> +{% endblock %} -- GitLab