aboutsummaryrefslogtreecommitdiff
path: root/resources/views/errors
diff options
context:
space:
mode:
authorFrankie B <git@diskfloppy.me>2024-01-12 18:57:10 +0000
committerFrankie B <git@diskfloppy.me>2024-01-12 18:57:33 +0000
commit725712aa35a989f1c2f179e210b8fa1c310e39e9 (patch)
tree4ba81858541a5db1e16839dd780af06ec0e5872d /resources/views/errors
parentc622761799635392cc35a46795955c9a0be12fc1 (diff)
Add custom error pages, pixel images, etc (also improve computers)
Diffstat (limited to 'resources/views/errors')
-rw-r--r--resources/views/errors/401.blade.php5
-rw-r--r--resources/views/errors/402.blade.php5
-rw-r--r--resources/views/errors/403.blade.php5
-rw-r--r--resources/views/errors/404.blade.php30
-rw-r--r--resources/views/errors/418.blade.php5
-rw-r--r--resources/views/errors/419.blade.php5
-rw-r--r--resources/views/errors/429.blade.php5
-rw-r--r--resources/views/errors/500.blade.php5
-rw-r--r--resources/views/errors/503.blade.php5
-rw-r--r--resources/views/errors/layout.blade.php53
-rw-r--r--resources/views/errors/minimal.blade.php21
11 files changed, 144 insertions, 0 deletions
diff --git a/resources/views/errors/401.blade.php b/resources/views/errors/401.blade.php
new file mode 100644
index 0000000..5c586db
--- /dev/null
+++ b/resources/views/errors/401.blade.php
@@ -0,0 +1,5 @@
+@extends('errors::minimal')
+
+@section('title', __('Unauthorized'))
+@section('code', '401')
+@section('message', __('Unauthorized'))
diff --git a/resources/views/errors/402.blade.php b/resources/views/errors/402.blade.php
new file mode 100644
index 0000000..3bc23ef
--- /dev/null
+++ b/resources/views/errors/402.blade.php
@@ -0,0 +1,5 @@
+@extends('errors::minimal')
+
+@section('title', __('Payment Required'))
+@section('code', '402')
+@section('message', __('Payment Required'))
diff --git a/resources/views/errors/403.blade.php b/resources/views/errors/403.blade.php
new file mode 100644
index 0000000..a5506f0
--- /dev/null
+++ b/resources/views/errors/403.blade.php
@@ -0,0 +1,5 @@
+@extends('errors::minimal')
+
+@section('title', __('Forbidden'))
+@section('code', '403')
+@section('message', __($exception->getMessage() ?: 'Forbidden'))
diff --git a/resources/views/errors/404.blade.php b/resources/views/errors/404.blade.php
new file mode 100644
index 0000000..79ca498
--- /dev/null
+++ b/resources/views/errors/404.blade.php
@@ -0,0 +1,30 @@
+@extends('errors::minimal')
+@php
+abort(503)
+@endphp
+@section('content')
+
+<h1>Error 404 | <strong>Page not found!</strong></h1>
+<hr align="left">
+<h2>The page <code class="addr">/{{ Request::path() }}/</code> doesn't exist! Did you mean...</h2>
+<ul>
+ <li><a href="//www.diskfloppy.me/">diskfloppy.me</a></li>
+ <li><a href="//git.diskfloppy.me/">git.diskfloppy.me</a></li>
+ <li><a href="//weather.diskfloppy.me">weather.diskfloppy.me</a></li>
+ <li><a href="//dl.diskfloppy.me/">dl.diskfloppy.me</a></li>
+ <li><a href="https://status.diskfloppy.me">status.diskfloppy.me</a> (HTTPS Only)</li>
+ <li><a href="gopher://diskfloppy.me">gopher://diskfloppy.me</a></li>
+</ul>
+<p>Still haven't found what you were looking for or believe this is a server error? Contact the <a href="mailto:webmaster@diskfloppy.me">webmaster</a>!</p>
+<br>
+<h4>Diagnostic Info</h4>
+<table><tr><td>
+ <code>
+ Server: &nbsp;{{ gethostname() }}<br>
+ Your IP: {{ Request::ip() }}<br>
+ Epoch: &nbsp;&nbsp;{{ now()->timestamp }}<br>
+ Agent: &nbsp;&nbsp;Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:122.0) Gecko/20100101 Firefox/122.0 </code>
+ </td></tr></table>
+<hr align="left">
+<p>&copy; floppydisk 2021-2024</p>
+@endsection
diff --git a/resources/views/errors/418.blade.php b/resources/views/errors/418.blade.php
new file mode 100644
index 0000000..412ea92
--- /dev/null
+++ b/resources/views/errors/418.blade.php
@@ -0,0 +1,5 @@
+@extends('errors::minimal')
+
+@section('title', __('I\'m a teapot'))
+@section('code', '418')
+@section('message', __('I\'m a teapot'))
diff --git a/resources/views/errors/419.blade.php b/resources/views/errors/419.blade.php
new file mode 100644
index 0000000..c09216e
--- /dev/null
+++ b/resources/views/errors/419.blade.php
@@ -0,0 +1,5 @@
+@extends('errors::minimal')
+
+@section('title', __('Page Expired'))
+@section('code', '419')
+@section('message', __('Page Expired'))
diff --git a/resources/views/errors/429.blade.php b/resources/views/errors/429.blade.php
new file mode 100644
index 0000000..f01b07b
--- /dev/null
+++ b/resources/views/errors/429.blade.php
@@ -0,0 +1,5 @@
+@extends('errors::minimal')
+
+@section('title', __('Too Many Requests'))
+@section('code', '429')
+@section('message', __('Too Many Requests'))
diff --git a/resources/views/errors/500.blade.php b/resources/views/errors/500.blade.php
new file mode 100644
index 0000000..d9e95d9
--- /dev/null
+++ b/resources/views/errors/500.blade.php
@@ -0,0 +1,5 @@
+@extends('errors::minimal')
+
+@section('title', __('Server Error'))
+@section('code', '500')
+@section('message', __('Server Error'))
diff --git a/resources/views/errors/503.blade.php b/resources/views/errors/503.blade.php
new file mode 100644
index 0000000..c5a9dde
--- /dev/null
+++ b/resources/views/errors/503.blade.php
@@ -0,0 +1,5 @@
+@extends('errors::minimal')
+
+@section('title', __('Service Unavailable'))
+@section('code', '503')
+@section('message', __('Service Unavailable'))
diff --git a/resources/views/errors/layout.blade.php b/resources/views/errors/layout.blade.php
new file mode 100644
index 0000000..019c2cd
--- /dev/null
+++ b/resources/views/errors/layout.blade.php
@@ -0,0 +1,53 @@
+<!DOCTYPE html>
+<html lang="en">
+ <head>
+ <meta charset="utf-8">
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+
+ <title>@yield('title')</title>
+
+ <!-- Styles -->
+ <style>
+ html, body {
+ background-color: #fff;
+ color: #636b6f;
+ font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
+ font-weight: 100;
+ height: 100vh;
+ margin: 0;
+ }
+
+ .full-height {
+ height: 100vh;
+ }
+
+ .flex-center {
+ align-items: center;
+ display: flex;
+ justify-content: center;
+ }
+
+ .position-ref {
+ position: relative;
+ }
+
+ .content {
+ text-align: center;
+ }
+
+ .title {
+ font-size: 36px;
+ padding: 20px;
+ }
+ </style>
+ </head>
+ <body>
+ <div class="flex-center position-ref full-height">
+ <div class="content">
+ <div class="title">
+ @yield('message')
+ </div>
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/resources/views/errors/minimal.blade.php b/resources/views/errors/minimal.blade.php
new file mode 100644
index 0000000..e15c833
--- /dev/null
+++ b/resources/views/errors/minimal.blade.php
@@ -0,0 +1,21 @@
+@extends('layouts.minimal')
+@section('content')
+ <h1>Error @yield('code') | <strong>@yield('message')</strong></h1>
+ <hr align="left">
+ <p>Here, have a cat...</p>
+ <img src="https://http.cat/@yield('code')" width="500"><br><br>
+ <p>If you believe this is a server error, contact the <a href="mailto:webmaster@diskfloppy.me">webmaster</a></p>
+ <br>
+ <h4>Diagnostic Info</h4>
+ <table><tr><td>
+ <code>
+ Server: &nbsp;{{ gethostname() }}<br>
+ Your IP: {{ Request::ip() }}<br>
+ Root: &nbsp;&nbsp;&nbsp;{!! url('') !!}<br>
+ Path: &nbsp;&nbsp;&nbsp;/{{ Request::path() }}/<br>
+ Epoch: &nbsp;&nbsp;{{ now()->timestamp }}<br>
+ Agent: &nbsp;&nbsp;Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:122.0) Gecko/20100101 Firefox/122.0 </code>
+ </td></tr></table>
+ <hr align="left">
+ <p>&copy; floppydisk 2021-2024</p>
+@endsection