fixed 404

This commit is contained in:
ocueye2 2024-08-20 17:09:36 +00:00
parent 5a3f55920d
commit cd3800ec5a
3 changed files with 13 additions and 14 deletions

5
css/404.css Normal file
View File

@ -0,0 +1,5 @@
h1 {
color: red;
}

View File

@ -1,4 +1,4 @@
port = 8080
port = 1111
import os
import sys
@ -147,8 +147,6 @@ class MyHandler(SimpleHTTPRequestHandler):
self.send_header('Content-type', 'text/html')
self.end_headers()
# Merge all the files together procedrealy
# todo: make compiler verson of this
@ -175,19 +173,12 @@ class MyHandler(SimpleHTTPRequestHandler):
"""
print(paths.replace("/",""))
self.send_response(404)
self.end_headers()
self.send_response(200)
self.send_header('Content-type', 'text/html')
self.end_headers()
content = ""
self.wfile.write(content.encode())
print(content)
self.end_headers()
# Set the server address and port
server_address = ('', port)

View File

@ -1,3 +1,6 @@
<h1> uh oh </h1>
<p>This is 404.html for when the page could not be found</p>
<p>This is 404.html for when the page could not be found</p>
<p>this is an error with finding the location of a file, its probly not easyweb (hopefully)</p>
<br>
<p>make sure the files are in the right place (html is in /html/ css in /css/ etc).</p>