PSP / mod_python ... how to get POST vars on .psp ?
Steve Holden
steve at holdenweb.com
Mon Jun 6 22:34:42 EDT 2005
poisondart wrote [without quoting the question]:
> Would something like cgi.FieldStorage() be what you're looking for?
>
> form = cgi.FieldStorage()
>
> form[ <name of variable here> ] = <value of variable>
>
> http://www.python.org/doc/2.3.5/lib/node406.html
>
The problem with that would be that cgi.FieldStorage [checks manual ...]
reads standard input, while mod_python appears to make the input
available through the request's read() method. So you would need to
temporarily replace the process's standard input with the request object.
I don't guarantee that would *work*, mind. It would just be a bit less
wrong :-)
regards
Steve
--
Steve Holden +1 703 861 4237 +1 800 494 3119
Holden Web LLC http://www.holdenweb.com/
Python Web Programming http://pydish.holdenweb.com/
More information about the Python-list
mailing list