#!/usr/bin/python2 import CGIHTTPServer import BaseHTTPServer class Handler(CGIHTTPServer.CGIHTTPRequestHandler): cgi_directories = ["/"] PORT = 1337 httpd = BaseHTTPServer.HTTPServer(("", PORT), Handler) #print "serving at port", PORT httpd.serve_forever()