updating templates to have dedicated wordpress login page, updated phpmyadmin page to be more correct

This commit is contained in:
Phillip Tarrant
2025-12-25 13:35:42 -06:00
parent 9128d2759f
commit 47a49b03be
5 changed files with 516 additions and 19 deletions

View File

@@ -249,18 +249,19 @@ class Handler(BaseHTTPRequestHandler):
self.wfile.write(api_response('/api/config').encode())
return True
if path in ['/admin', '/admin/', '/admin/login', '/login', '/wp-login.php']:
if path in ['/admin', '/admin/', '/admin/login', '/login']:
self.send_response(200)
self.send_header('Content-type', 'text/html')
self.end_headers()
self.wfile.write(html_templates.login_form().encode())
return True
if path == '/wp-admin' or path == '/wp-admin/':
# WordPress login page
if path in ['/wp-login.php', '/wp-login', '/wp-admin', '/wp-admin/']:
self.send_response(200)
self.send_header('Content-type', 'text/html')
self.end_headers()
self.wfile.write(html_templates.login_form().encode())
self.wfile.write(html_templates.wp_login().encode())
return True
if path in ['/wp-content/', '/wp-includes/'] or 'wordpress' in path.lower():