0
我有這個在我的python腳本Python的 - CGI字段存儲錯誤
form = cgi.FieldStorage()
print form
print form.getvalue("param")
二號線打印FieldStorage(None, None, 'param=abcd')
和3號線會導致錯誤
File "/var/www/cgi-bin/use_save.py", line 24, in <module>
print form.getvalue("param")
File "/usr/lib64/python2.7/cgi.py", line 548, in getvalue
if key in self:
File "/usr/lib64/python2.7/cgi.py", line 594, in __contains__
raise TypeError, "not indexable"
TypeError: not indexable
是什麼原因造成這個錯誤的值是隻傳遞一個字符串?