import.py
changeset 57 31271426f879
parent 56 6b31934e5b2e
child 58 004a32370ba5
equal deleted inserted replaced
56:6b31934e5b2e 57:31271426f879
     1 #!/usr/bin/python
       
     2 
       
     3 import sys
       
     4 import traceback
       
     5 sys.path.insert(0, "/home/fabien/lib/python")
       
     6 sys.path.insert(0, "./lib")
       
     7 sys.stderr = sys.stdout
       
     8 
       
     9 print "Content-type: text/html; charset=iso-8859-1;"
       
    10 print
       
    11 
       
    12 # import cgitb; cgitb.enable()
       
    13 import cgi
       
    14 from templates import Template
       
    15 from os import environ
       
    16 
       
    17 def main():
       
    18     db = my_db.connect(environ["REMOTE_USER"])
       
    19     tmpl = Template("import.tmpl", db.get_preferences())
       
    20     print tmpl.process()
       
    21 
       
    22 if (__name__ == "__main__"):
       
    23     main()