Note that there are some explanatory texts on larger screens.

plurals
  1. POdoes python BaseHttpServer support Html5?
    primarykey
    data
    text
    <p>I am using BaseHttpServer of Python-2.6.6. I could not make it work with tag. Does Python-2.6 really support HTML5 ? </p> <p>This could be more helpful:</p> <pre><code>Traceback (most recent call last): File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 283, in _handle_request_noblock self.process_request(request, client_address) File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 309, in process_request self.finish_request(request, client_address) File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 322, in finish_request self.RequestHandlerClass(request, client_address, self) File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/SocketServer.py", line 617, in __init__ self.handle() File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 329, in handle self.handle_one_request() File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 323, in handle_one_request method() File "testServer.py", line 43, in do_GET self.send_error(404,'File Not Found: %s' % self.path) File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 357, in send_error self.send_response(code, message) File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/BaseHTTPServer.py", line 382, in send_response (self.protocol_version, code, message)) File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/socket.py", line 318, in write self.flush() File "/opt/local/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/socket.py", line 297, in flush self._sock.sendall(buffer(data, write_offset, buffer_size)) error: [Errno 32] Broken pipe </code></pre> <p>Server Side:</p> <pre><code>if self.path.endswith(".ts"): f = open("simpsons.ts", 'r') self.send_response(200) self.send_header('Content-type', 'video/mpegts') self.end_headers() self.wfile.write(f.read()) return </code></pre> <p>Client Side: </p> <pre><code>video width='320' height='240' src="simpsons.ts" controls="controls" /video </code></pre> <p>Image Code(Working): </p> <p>Server Side:</p> <pre><code>if self.path.endswith(".png"): f = open("ps_logo2.png", 'r') self.send_response(200) self.send_header('Content-type', 'image/png') self.end_headers() self.wfile.write(f.read()) return </code></pre> <p>Client Side: </p> <pre><code>img src="ps_logo2.png" alt="No Image"/ </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload