index.cgi
changeset 7 d6a8258bd90e
parent 6 5565d94da522
child 11 fa216534ae45
equal deleted inserted replaced
6:5565d94da522 7:d6a8258bd90e
     1 #!/usr/bin/python2.5
     1 #!/usr/bin/python2.5
       
     2 # :set filetype=py encoding=utf8
     2 
     3 
       
     4 """
       
     5     CGI implementation
       
     6 """
     3 
     7 
       
     8 # CGI handler for WSGI
       
     9 import wsgiref.handlers
       
    10 
       
    11 # our WSGI app
       
    12 from lib import wsgi
       
    13 
       
    14 def cgi_main () :
       
    15     """
       
    16         Run in CGI mode
       
    17     """
       
    18     
       
    19     # create handler
       
    20     cgi_handler = wsgiref.handlers.CGIHandler()
       
    21     
       
    22     # run once
       
    23     cgi_handler.run(wsgi.app)
       
    24 
       
    25 if __name__ == '__main__' :
       
    26     cgi_main()