Update meshenger_clientserve.py

serve the webapp.html on every url requested
This commit is contained in:
dennisdebel 2014-05-04 13:44:53 +02:00
parent 440c794de7
commit ec18d8db6f

View File

@ -32,10 +32,12 @@ class ClientServeHandler(SimpleHTTPServer.SimpleHTTPRequestHandler):
return SimpleHTTPServer.SimpleHTTPRequestHandler.do_GET(self)
else:
self.send_response(404)
self.send_response(200) #serve the webapp on every url requested
self.send_header('Content-type', 'text/html')
self.end_headers()
self.wfile.write('404 - Not Found')
f = os.path.join( "webapp.html")
with open( f, 'r') as the_file:
self.wfile.write(the_file.read())
"""