Pastebin

Paste #2575: server.py

< previous paste - next paste>

Pasted by Anonymous Coward

Download View as text

#!/usr/bin/env python

import BaseHTTPServer
import CGIHTTPServer
import cgitb; cgitb.enable()  ## This line enables CGI error reporting

server = BaseHTTPServer.HTTPServer
handler = CGIHTTPServer.CGIHTTPRequestHandler
server_address = ("", 8000)
handler.cgi_directories = [""]

httpd = server(server_address, handler)
httpd.serve_forever()

New Paste


Do not write anything in this field if you're a human.

Go to most recent paste.