Automatically exported from code.google.com/p/planningalerts
No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.

CGITemplate 734 B

hace 17 años
hace 16 años
1234567891011121314151617181920212223242526272829
  1. # This is the parser for %(authority_name)s.
  2. # it is generated from the file CGITemplate
  3. import cgi
  4. import cgitb
  5. #cgitb.enable(display=0, logdir="/tmp")
  6. form = cgi.FieldStorage()
  7. day = form.getfirst('day')
  8. month = form.getfirst('month')
  9. year = form.getfirst('year')
  10. authority_name = "%(authority_name)s"
  11. authority_short_name = "%(authority_short_name)s"
  12. base_url = "%(base_url)s"
  13. #print "Content-Type: text/html" # HTML is following
  14. #print
  15. print "Content-Type: text/xml; charset=utf-8" # XML is following
  16. print
  17. import %(module)s
  18. parser = %(module)s.%(parser)s(authority_name, authority_short_name, base_url)
  19. xml = parser.getResults(day, month, year)
  20. print xml.encode("utf-8") # print the xml