#!/usr/bin/python import CGIHTTPServer import BaseHTTPServer import webbrowser class Handler(CGIHTTPServer.CGIHTTPRequestHandler): cgi_directories = ["/cgi-bin"] PORT = 8008 httpd = BaseHTTPServer.HTTPServer(("", PORT), Handler) print "serving at port", PORT webbrowser.open('http://localhost:8008/siyaedit.html') httpd.serve_forever()