-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
24c5f32
commit 8c2a6d6
Showing
2 changed files
with
24 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -23,7 +23,7 @@ | |
</head> | ||
<body> | ||
|
||
<h2>Filter Data</h2> | ||
<h2>Search Logs</h2> | ||
|
||
<form id="filterForm"> | ||
<table> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import http.server | ||
import socketserver | ||
import webbrowser | ||
import os | ||
|
||
PORT = 4000 | ||
|
||
# Define a custom handler to serve files | ||
Handler = http.server.SimpleHTTPRequestHandler | ||
|
||
# Change the current working directory to the directory containing index.html | ||
web_dir = "." | ||
os.chdir(web_dir) | ||
|
||
# Start the server | ||
with socketserver.TCPServer(("", PORT), Handler) as httpd: | ||
print(f"Serving at port {PORT}") | ||
|
||
# Open the default web browser | ||
webbrowser.open(f"http://localhost:{PORT}/index.html") | ||
|
||
# Keep the server running until interrupted | ||
httpd.serve_forever() |