if Request("something") == None: doesn't work
Sam Sungshik Kong
ssk at chol.nospam.net
Wed May 12 13:12:00 EDT 2004
Hello!
I use Python for ASP programming.
I found something weird.
Response.Write(Request("something"))
It draws "None" when there's no value for something.
Actually I expect "" instead of "None".
So I changed it like
if Request("something") == None:
Response.Write("")
else:
Response.Write(Request("something"))
Strangely, the result of comparison is False.
if str(Request("something")) == "None":
works!
Also,
if len(Request("something")) == 0:
works!
What's wrong?
ssk
More information about the Python-list
mailing list