]>
git.scottworley.com Git - hellowebpy/blob - hellowebpy.py
113911cef2f0bcea8a14e6ec560dc30ced4efe73
1 from http
.server
import BaseHTTPRequestHandler
, HTTPServer
3 listen_address
= ('', 8080)
6 class HelloServer(BaseHTTPRequestHandler
):
7 def do_GET(self
) -> None:
8 self
.send_response(200)
9 self
.send_header("Content-type", "text/html")
11 self
.wfile
.write(bytes("<html><body>Hello Web</body></html>", "utf-8"))
15 webServer
= HTTPServer(listen_address
, HelloServer
)
16 webServer
.serve_forever()
19 if __name__
== "__main__":