Skip to content

Commit

Permalink
feat: add 404 page design
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrew4Coding committed Oct 11, 2024
1 parent ce1dae9 commit e81653d
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 5 deletions.
1 change: 1 addition & 0 deletions eventyog/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@

# SECURITY WARNING: don't run with debug turned on in production!
DEBUG = not PRODUCTION
DEBUG = False

ALLOWED_HOSTS = ['*']

Expand Down
8 changes: 4 additions & 4 deletions modules/authentication/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
app_name = 'auth'

urlpatterns = [
path('/login', login_user, name='login'),
path('/logout', logout_user, name='logout'),
path('/register', register, name='register'),
path('/profile', profile, name='profile')
path('login', login_user, name='login'),
path('logout', logout_user, name='logout'),
path('register', register, name='register'),
path('profile', profile, name='profile')
]
18 changes: 18 additions & 0 deletions templates/404.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{% extends "base.html" %}
{% block content%}
<main class="p-20 flex items-center justify-center h-screen w-full flex flex-col gap-4">
<h1 class="text-5xl font-bold">
404
</h1>
<p>
Sorry, the page you are looking for could not be found.
</p>
<a href="{% url 'main:main' %}">
<button
class="bg-[#003FE2] text-white py-3 px-10 text-sm font-semibold rounded-3xl hover:scale-105 duration-300"
>
Go back to home
</button>
</a>
</main>
{% endblock content%}
2 changes: 1 addition & 1 deletion templates/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
{% if show_navbar %}
{% include "ds/navbar.html" %}
{% endif %}
<div class="container h-full min-h-screen">
<div class="h-full min-h-screen w-full">
{% block content %}{% endblock content%}
</div>

Expand Down
Empty file removed templates/ds/404.html
Empty file.

0 comments on commit e81653d

Please sign in to comment.