cgi Module

JS scjuonline at web.de
Sat Feb 8 12:12:59 EST 2003


Hi,

I have a question about the cgi module:

I would like to write a robust cgi programm which checks all the parameters.

Possible calls are:

1.) http://www.example.com/cgi-bin/test.py
2.) http://www.example.com/cgi-bin/test.py?param
3.) http://www.example.com/cgi-bin/test.py?param=
4.) http://www.example.com/cgi-bin/test.py?param=xyz
5.) param=file (POST)

form = cgi.FieldStorage() gives me in cases 1+2+3 nothing?

Shouldn't case 2 be param==None
and case 3 param=="" ?

thx a lot,

JS











More information about the Python-list mailing list